Michael Pavling wrote: > On 26 May 2010 08:34, nirosh <[email protected]> wrote: >> use like this it will send the @myfriendlogin array to partial >> format.html { render :partial => 'users/dispfriends', �:locals >> =>{ :user=>@myfriendlogin} > > No. > > There's no need to use :locals from the controller. The @myfriendlogin > is passed automagically to the view. > You can use the :collection attribute to let Rails do the iteration > from the controller (not very flexible if you want anything else in > the view), or do it yourself inside the view to render a partial > several times there (see page 119 of the 3rd edition of "Agile Web > Development with Rails").
Thank you All for your replies. I got the required output. Thanks. -- 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.

