Using check_box with onclick javascript

627 views
Skip to first unread message

kimda

unread,
Jan 18, 2008, 4:24:15 PM1/18/08
to Ruby on Rails: Talk
Hi,

I am trying to use onclick javascript event, but this doesn't work:

<%= check_box("attending_ip", 'pm_xray',{},
'y', :onclick=>"insertToDo();" ) %>

how do I make this correct?

thanks,

kimda

unread,
Jan 18, 2008, 6:09:07 PM1/18/08
to Ruby on Rails: Talk
I found the solution:

<%= check_box("attending_ip", 'pm_xray',
{:onclick=>"insertToDo('pm_xray');"}, 'y' ) %>

Roxanne Cwikowski

unread,
Feb 3, 2008, 10:04:05 AM2/3/08
to rubyonra...@googlegroups.com
Daniel Kim wrote:
> I found the solution:
>
> <%= check_box("attending_ip", 'pm_xray',
> {:onclick=>"insertToDo('pm_xray');"}, 'y' ) %>

can you explain what part relates to what please.


thanks

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

Reply all
Reply to author
Forward
0 new messages