Displaying 2 results from an estimated 2 matches for "disableenterkey".
2010 Oct 11
0
Converting observe_field to UJS in Rails 3
...s[:area] != nil%>
<% form_tag({:action => "foo"},{:id => "search"}) do %>
<%= label_tag(:query, "Search for:") %>
<%= text_field_tag("query", params[:query], :autocomplete =>
"off" , :onKeyPress=>"return disableEnterKey(event)") %>
<% end %>
<%= observe_field ''query'', :frequency => 2,
:update => "search_results",
:url => {:controller => params[:area], :action =>
"search",:area => params[:area]},
:method=>:get,...
2010 Oct 18
0
Ajax call-request.xhr? = false Rails 3
...ms[:area], :action
=> :search, :area => params[:area] }), :method => :get, :remote =>
true do %>
<%= label_tag(:query, "Search for:") %>
<%= text_field_tag("query", params[:query], :autocomplete =>
"off", :onKeyPress=>"return disableEnterKey(event)") %>
<%= submit_tag("Search", :name => nil, ) %>
On reaching the controller in question request.xhr? is = to false
Anyone has any ideas why? or what am I doing wrong.
I have prototype.js and rails.js files loaded in my layout files.
--
You received thi...