Displaying 4 results from an estimated 4 matches for "javascript_expansions".
2010 Sep 09
0
Rails3: jquery-rails gem sets 'config.action_view.javascript_expansions' but cannot be overriden in 'config/application.rb'
Hello,
I''ve created a new Rails3 app and I''m using jQuery instead of prototype.
Gemfile:
gem ''jquery-rails''
in my config/application.rb I want do the following:
config/application.rb
if Rails.env.production?
config.action_view.javascript_expansions[:defaults] = %w(jquery.min
rails application)
else
config.action_view.javascript_expansions[:defaults] = %w(jquery rails
application)
end
So in production I want to include jquery.min whereas in development I want
the unminified (jquery).
But this seems not to work and when I look at the jqu...
2011 May 25
1
trouble using jQuery in Rails 3.0.7
...e="text/javascript" charset="utf-8">
$("a").click(function() {
alert("Hello world!");
});
</script>
Any ideas as to what I''m missing? I''ve tried both commenting out and
uncommenting this line in application.rb:
config.action_view.javascript_expansions[:defaults] = %w(jquery rails)
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To unsubscribe from this group, send email t...
2010 Nov 04
9
Delete action is not working and redirects to edit action
Hello,
i have a strange problem here. I have made a teacher controller using
scaffold. All actions work fine but the delete does not. When i click
the delete link, it redirects me to the edit of this teacher. I have
restarted the server and i have tried in firefox (i use chrome) but
problem still remains. Here is the code from my view.
<%= link_to(image_tag("/images/
2011 Oct 21
20
How to transform my html form into a rails 3 form
Hi,
I have the following code working in a rails 3 view, but it is
unfortunately not pure rails code!
<% @filter1 = "tr.show1,tr.show2" %>
<% @filter2 = "tr.show1" %>
<% @filter3 = "tr.show2" %>
<form>
<p>
<input type="checkbox" value=<%=@filter1%> onclick="$
(this).is('':checked'')