Sign in through GitHub

Please read for an updated status on RailsCasts:

Learn more or hide this

Erick Alvarez's Profile

GitHub User: erick75

Comments by Erick Alvarez

Avatar

apply the pagination until the format.html inside respond_to
format.html { over here }

this way format.csv is not affected by paging

Avatar

You can use
<%= link_to "Excel", user_contacts_path(params.merge(format: 'xls')) %>

and this will maintain the current parameters you have plus the ones you add or edit inside merge.