CodeIgniter Forums
route - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: route (/showthread.php?tid=52587)



route - El Forum - 06-17-2012

[eluser]anyamanggar[/eluser]
i want edit my data with form, the url like this :
http://localhost/mitra/edit/41.html

as to what to code for the route, like this ? :
$route['edit/(:any)'] = 'web/edit/view';




route - El Forum - 06-18-2012

[eluser]nagata[/eluser]
$route[‘edit/(:any)’] = ‘web/edit/view’;
would mean it is like [domain]/index.php/edit/41
to make it without index.php it would require more advanced configuration of CI AND Server.
to reach the /mitra/ its simply
$route[‘/mitra/edit/(:any)’] = ‘web/edit/view’;
and about the .html, not sure if its possible at all, and if is would require extra .htaccess configurating...