[eluser]WanWizard[/eluser]
There are several design decisions made that influence this (in 1.7.2):
The Input library assumes that 'enable_query_strings' == 'allow_get_array', which is not the case. The first one is your config 'switch' to decide if you want to use URI segments or the query string to define the controller/method load, the second one whether or not to erase the $_GET array. This two functions need to be split (and a config value needs to be defined for the latter).
The URI library (protocol == 'AUTO') assumes that if the $_GET array has values, they should be used for determining the URI string. Which is not the case, the 'enable_query_string' should be used to determine that. This has been correctly implemented in the Router class (_set_routing).
Structural solution for CI v1.7.2:
- add a new config variable 'allow_get_array' (boolean, default FALSE)
- in ./system/codeigniter/Codeigniter.php, move loading the Input class up, between the Config and the URI class
- in the Input library, create a new class variable 'enable_query_strings', and assign the config value to it
- in the Input library constructor, load and store the 'allow_get_array' value separate from the 'enable_query_strings' value
- in the URI library, only use $_GET if 'enable_query_strings' is TRUE
Diff for these changes in attachment.
I'll have a peek at 2.0 as well...