enter live(). implementing this function solved my problem.

http://docs.jquery.com/Events/live#typefn

On Aug 10, 9:47 am, Ram <yourstruly.vi...@gmail.com> wrote:
> anyone?? anything?
>
> On Aug 7, 4:36 pm, Ram <yourstruly.vi...@gmail.com> wrote:
>
> > Hi,
>
> > I have the followingjQueryfunction on the head of my page.
>
> > <script type="text/javascript">
> >                jQuery.noConflict();
>
> >                 /* calling jNice on document ready */
> >                jQuery(document).ready(function($)
> >                 {
> >                         $('div.jNice').jNice();
> >                 });
> > .....
> > </script>
>
> > On page load, this gets called correctly.
>
> > Now there's a link on the page that lets me add more rows and i do
> > this via RJS. Here's the code.
>
> > <tr id="empty_item">
> >     <div  id="plussign"><%= add_item_link "+" %></div>
> > </tr>
>
> > def add_item_link(name)
> >    link_to_function name do |page|
> >      page.insert_html :before, :empty_item, :partial=>'item', :object
> > => Item.new
> >    end
> > end
>
> > Now this partial 'item' contains form elements upon which jNice needs
> > to work its magic.
>
> > How can I call the jNice function after the user clicks on the
> > add_item_link?
> > Thanks.
--~--~---------~--~----~------------~-------~--~----~
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 rubyonrails-talk@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to