I am having some real issues with my rewrite on the .htaccess for my GoDaddy Account. I found a few web pages that have a lot of help but I am unable to get it to work on my sites in a positive way.
I have 2 sites that I need to figure out how to get the rewrite to work. Site one (mmh.com) is in the root directory. Site two (mhm.com) is in the folder /mhm off of the root directory.
First I need mmh.com to do a 301 redirect to mhm.com.
And then I need to be able to do "pretty permalinks" to the following address:
mhm.com/event.php?url=event-name-here
Here's what I've got and I have placed it in the ROOT (mmh.com) Directory:
Options +FollowSymLinks
RewriteEngine On
RewriteBase /
############## rewrite to www.mhm.com
RewriteCond %{HTTP_HOST} ^mhm\.com [NC]
RewriteRule (.*) http://www.mhm.com/$1 [R=301,L,NC]
RewriteCond %{HTTP_HOST} ^mmh\.com [NC]
RewriteRule (.*) http://www.mhm.com/$1 [R=301,L,NC]
RewriteCond %{HTTP_HOST} ^www.mmh\.com [NC]
RewriteRule (.*) http://www.mhm.com/$1 [R=301,L,NC]
################
##############
RewriteCond %{REQUEST_FILENAME} !-f
# uncomment if you want to exclude certain URLs: RewriteCond %{REQUEST_URI} !example.php
RewriteCond %{REQUEST_URI} !(.*)/$
RewriteRule ^mhm/(.*)$ http://www.mhm.com/$1/ [L,R=301]
#################
I know it can be done because I have wordpress, joomla and other open sources that work on my other godaddy hosting just fine. I've tried to use the coding for that to apply to these sites and it doesn't seem to work. It is turned on because I was able to redirect mmh.com to mhm.com for a while but I messed it up somewhere along the lines.
edit: of course GoDaddy doesn't help with .htaccess files and I'd really prefer to stick with them.