On the homepage of my web app I'm implementing pagination with ajax as well as an autocomplete search.
The script I used for the ajax pagination is here: http://wiki.github.com/mislav/will_paginate/ajax-pagination
The script I used for autocomplete search is detailed in my own answer to this question: http://stackoverflow.com/questions/1911077/rails-autocomplete-tag-search-filter/1925020#1925020
Each of these function just fine separately, but they don't work at all together. I believe this has something to do with the controller code but I'm not sure what.
I tried doing this but it didn't work:
format.js do
#For Auto complete
render :inline => "<%= auto_complete_result(@search_tags, 'name') %>"
#For Pagination with ajax
render :update do |page|
page.replace 'result', :partial => "search results"
end
end
If I comment out auto complete, pagination with ajax works. If I comment out pagination with ajax the autocomplete works.
What should I be doing here to make both of them work?