Jump to content

mod rewrite woes


ironhamster88

Recommended Posts

Hi guys / girls,

 

Ok, I have a slight problem with mod rewrite. My current URLs are as follows:

http://whatever.com/profile/?username=someuser

 

I need it to be:

http://whatever.com/profile/someuser

 

I've not spent much time at all working with mod-rewrite, can anybody help? I've got this so far but all I get is a 404.

 

RewriteEngine on
RewriteCond %{REQUEST_URI} !^/profile/ [NC]
RewriteRule ^([^/\.]+)/?$ /profile/index.php?id=$1 [L]

 

Cheers

Pete

Link to comment
https://forums.phpfreaks.com/topic/175019-mod-rewrite-woes/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.