Forum: Ferret Acts_as_ferret and Will_paginate

Posted by Dave Lynch (larrylep)
on 2010-06-08 15:28
I am running acts_as_ferret and will_paginate 2.3.11, I have the
following code in
controller
@ads = Ad.find_with_ferret(params[:q]+"~", :page => params['page'],
:per_page => 10)

View
<%@ads.collect do |@ad|%>
   <ul>
      <%= render :partial => 'content',:collect =>@ads -%>
   </ul>
<%end%>
<p><%= will_paginate @ads %></p>

The problem is it only paginates first page of results and I can't see
beyond the first page of results, (even if there is more than one page
of results)

Am getting nil value for page 2..3..next and so on

Any help would be greatly appreciated
Please log in before posting. Registration is free and takes only a minute.
Existing account (Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
No account? Register here.