Welcome Guest, Not a member yet? Register   Sign In
set config item 'permitted_uri_chars' individually for a specific controller ?
#1

[eluser]mmackay[/eluser]
Hi there, I'm keen on keeping the default permitted characters globally for my CI install but on one controller I really need to allow flexibility on what characters are permitted for the URI.

Is there any way to set the item dynamically when required in the necessary controller(s) ? I tried using $this->config->set_item('permitted_uri_chars', 'xxxx'); but it had no effect.

Is it at all possible ?

Thanks.

- Mike
#2

[eluser]Pascal Kriete[/eluser]
The permitted uri characters are checked in the URI class, which is called from the router. This is executed before the controller runs, so you won't be able to change it dynamically.

If you give us a little more information someone can probably help you come up with a viable solution.




Theme © iAndrew 2016 - Forum software by © MyBB