mod_rewrite to a specific controller - 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: mod_rewrite to a specific controller (/showthread.php?tid=14030) |
mod_rewrite to a specific controller - El Forum - 12-15-2008 [eluser]Phil Sturgeon[/eluser] What am I missing here? Quote:<IfModule mod_rewrite.c> I bolded the part with the issue. The idea is that example.com/profilename goes to the controller, while example.com/something.html or example.com/something/somethingelse.html all go through to index.php. The problem is, my first rule is ignored. Any ideas? It's late, I have been coding for almost 20 hours and I want to go to sleep... mod_rewrite to a specific controller - El Forum - 12-16-2008 [eluser]Pascal Kriete[/eluser] You're only checking for one character. Code: RewriteCond %{REQUEST_URI} ^/([a-zA-Z0-9_-]+)$ [NC] mod_rewrite to a specific controller - El Forum - 12-16-2008 [eluser]Phil Sturgeon[/eluser] HA! thanks very much Pascal, worked a treat. |