Hi Tom,

I came across your post looking for a solution myself. This is what's 
working for me:

<% form_remote_tag :url => { whatever_url } do -%>
<%= check_box_tag 'whatever', nil, whatever, { :onclick => 
"this.form.submit();", :disabled => false } %>
<% end -%>


Hope that helps, Cheers,
roark



Tom Ha wrote:
> Hi there,
> 
> I need to have a checkbox which ajax-submits a form.
> 
> The following code throws an error "index 112009 out of string". What's
> wrong here?
> 
> ==============================================
> <% form_remote_tag :url => { whatever_url } do -%>
> 
> <%= check_box_tag 'whatever', nil, whatever, { :onclick =>
> "#{remote_function('this.form.submit();')}", :disabled => false } %>
> 
> <% end -%>
> ==============================================
> 
> Thanks for any help with this!
> Tom

-- 
Posted via http://www.ruby-forum.com/.

-- 
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 [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to