If I had a link http://www.website.com/profile.php?user=Sam How could I make that url http://www.website.com/Sam I know this will be done in htaccess However how can I set this up. Awaiting your guru comments. Thanks, TJ
something like RewriteRule ^([a-zA-Z0-9]+)$ /profile.php?user=Sam [L,N] that should do what your asking, you'll also need to change your application to use the new url scheme as well.
Options FollowSymLinks RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ /profile.php?user=$1 [L,NC] Or Options FollowSymLinks RewriteEngine On RewriteRule ^([a-z0-9_-]+)$ /profile.php?user=$1 [L,NC] Also changing your code is needed to make it print out the correct URLs.
Im sorry I should have exalained that Sam Is data pulled from my tables. Therefore that has to be in there somehow. And needed intire mod rewrite rules to place in htaccess file as im completely new to rewrite.