CodeIgniter Forums
Remove class name from url - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forum-20.html)
+--- Forum: Archived General Discussion (https://forum.codeigniter.com/forum-21.html)
+--- Thread: Remove class name from url (/thread-31780.html)



Remove class name from url - El Forum - 06-30-2010

[eluser]Suhas nazir[/eluser]
Hai All

I am trying to change the name of controller name from url its working but take a look at the below problem

i change the route as
$route['function_name/:any']='mycontroller/function_name';
Suppose if there is a parameter like this mycontroller/function_name/12';
the value 12 is not get in the function ...
How i rewrite the route to make it possible
Thanks in advance;


Remove class name from url - El Forum - 07-01-2010

[eluser]cahva[/eluser]
EDIT: removed. Bad advice Smile

I had a little error there.. Heres the correct one:
Code:
$route['function_name/(:any)'] = "controller/method/$1";