Forum Moderators: phranque
Heres the whole file in case something else could affact it
RewriteEngine on
RewriteCond %{HTTP_HOST} ^mysite\.com
RewriteRule (.*) [mysite.com...] [R=301,L]
<FilesMatch "^[^\.]+$">
ForceType application/x-httpd-php
</FilesMatch>
DirectoryIndex index.html.var index.htm index.html index.php index
php_value register_globals Off
php_value track_vars On
php_value arg_separator.output "&"
php_value arg_separator.input "&"
Before setting out down this path, I suggest you consder adding a 'key' to the URL so that mod_rewrite can detect it. Otherwise, you may have to exclude a lot of files from being rewritten, and this list will grow over time.
For example, you could use URLs of the form
example.com/users/me
and then use the code:
RewriteRule ^users/([a-z_0-9]+)$ /journal?user=$1 [L]
Alternatively, if your host allows wild-card subdomains and will deliver requests for them to your Web root folder, you could use URLs like:
me.example.com
and change the code to get the username from the subdomain (excluding www, of course).
Jim