Re: Pagination + Search Parameters. How?

Eric A.
Wed, 09 May 2007 20:10:26 -0000

Hey Felipe,

First off, I don''t think :params => "" is a viable link_to
attribute and
second, im not sure you can put an array into the pagination method.

It depends on how you identify the text-field in the controller, but you
may want to try:

<%= text_field ''search'', ''name'' %>

<%= pagination_links(@users_pages, :searchname =>
params[:search][:name]) %>


Then you can call params[:searchname] in your controller to get whatever
was typed in the search name text_field.

Good Luck,
- Eric

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