I am using rails to build my application and I want a thickbox on clicking a particular link..
I use the below code in my partial which is displayed in a division of a page and on clicking the user.name, i need the thickbox.. when i use the below code, nothing happens..
<%= link_to_function user.name,remote_function(:update=>"result", :url => {:action => :resultsuser}, :with => "'id='+#{user.id}+'&height=400&width=600'") %>
i have included the
<%= javascript_include_tag 'jquery' %>
and also replaced all $ by jQuery in the thickbox.js file.. nothing happens..
<%= javascript_include_tag 'thickbox' %>
jQuery.noConflict()
<%= stylesheet_link_tag("thickbox") %>
please help me out.
views:
81answers:
2
A:
Try adding the class option in the link_to_function
helper method.
<%= link_to_function user.name,remote_function(:update=>"result", :url => {:action => :resultsuser}, :with => "'id='+#{user.id}+'&height=400&width=600'", :class => "thickbox") %>
punit
2009-09-14 18:03:16