can anyone suggest me how to remove undefined method ‘paginate’ in rails 2.3.8
here is my index method which shows index page and code of this is
def index
@clients = Client.paginate :page => params[:page], :per_page => 5
respond_to do |format|
format.html # index.html.erb
format.xml { render :xml => @clients }
end
end
Undefined method ‘paginate’ probably indicates that you don’t have will_paginate installed.
To get rid of your error you have to choices:
1) Get rid of pagination.
Replace
With
2) Install will_paginate by placing the following in your environment file:
and then running rake gems:install of cause. 🙂