Welcome Guest, Not a member yet? Register   Sign In
Controller with name 'list'

I want to create a controller with the name 'list' is it possible (and how) to override the reserved php keyword to use it.
Or could I solve it with routes? And how.


[eluser]Colin Williams[/eluser]
$route['list'] = 'my_list';
$route['list/(.+)'] = "my_list/$1";

Definitely solve it with routes, you really dont want to be going around overwriting PHP core functionality because its likely to cause you issues down the road.

[eluser]Colin Williams[/eluser]
List is an odd controller name, anyway. Pretty generic.

Theme © iAndrew 2016 - Forum software by © MyBB