I think...
Dont use #{....}

<%= check_box_tag 'whatever', nil, whatever, { :onclick =>
"remote_function('this.form.
>
> submit();')", :disabled => false } %>
>

But I dont because i never try it...
keep trying


On Wed, Mar 10, 2010 at 1:02 AM, Tom Ha <[email protected]> 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]<rubyonrails-talk%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/rubyonrails-talk?hl=en.
>
>


-- 

Senior Rails Developer
Anton Effendi - Wu You Duan

-- 
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