Hello mod_rewrite forum members,
I am here to ask you for help with my website. All I need is thomas.example.com to refer to example.com/name.php?name=thomas.
Thanks a lot in advance,
~tpad
RewriteEngine On
RewriteRule ^/(.*)$ /own.php?personname=%2 [QSA,L]
Object not found!
The requested URL was not found on this server. If you entered the URL manually please check your spelling and try again.
If you think this is a server error, please contact the webmaster.
Error 404
Options +FollowSymLinks
RewriteEngine On
# Rewrite sub domains.
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteCond %{HTTP_HOST} !^(www\.)?example\.com$ [NC]
RewriteCond %{HTTP_HOST} ^(www\.)?([^\.]+)\.example\.com$ [NC]
RewriteRule ^(.*)$ /name.php?name=%2&request_uri=$1 [QSA,L]
what was supposed to happen is when someone goes to hisname.example.com it would redirect him to example.com/name.php?personname=hisname.
When someone writes something there it should be ignored
&request_uri=$1
Users browsing this forum: No registered users and 51 guests