CodeIgniter Forums
Pagination & Search Queries - Printable Version

+- CodeIgniter Forums (
+-- Forum: Archived Discussions (
+--- Forum: Archived Development & Programming (
+--- Thread: Pagination & Search Queries (/thread-55245.html)

Pagination & Search Queries - El Forum - 10-16-2012

I'm having some trouble with a search feature in my current project. I have results that are displayed normally across several pages using pagination. However, when trying to add a custom search term it completely breaks the pagination.

Is there an elegant solution to making pagination work with search queries?

I noticed there is a config option to change how the URL's for pagination are setup

$config['page_query_string'] = TRUE

Which would turn


But when I try to use it I get an "The URI you submitted has disallowed characters." error.

I'm sure others have faced this problem but I can't seem to find a good solution as of right now

Pagination & Search Queries - El Forum - 10-17-2012

[eluser]Mr. Pickle[/eluser]
If you want to use GET parameters you have to allow it in the CI config file, I guess it's called:

$config['enable_query_strings'] = TRUE;