views:

110

answers:

1

I moved my cakephp site from a subdomain over to a different domain. I handled the permanent redirect in my htaccess file but in the redirect i am losing my neat/clean url handling.

old site
iphone.gameachievements.org

new site
gameachievements.org

example of current redirect
iphone.gameachievements.org/games/jungle-swing -> gameachievements.org/index.php?url=games/jungle-swing

what i want.. is
iphone.gameachievements.org/games/jungle-swing -> gameachievements.org/games/jungle-swing

here is what my htaccess file looks like...

<IfModule mod_rewrite.c>

    RewriteEngine On
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^(.*)$ index.php?url=$1 [QSA,L]
    RewriteCond %{HTTP_HOST} iphone.gameachievements.org
    RewriteRule (.*) http://gameachievements.org/$1 [R=301,L]
</IfModule>

any help is appricated thanks

m!

+1  A: 

Put this first:

RewriteCond %{HTTP_HOST} iphone.gameachievements.org
RewriteRule (.*) http://gameachievements.org/$1 [R=301,L]
jholster
that worked beautifully. thank you.
veryMickey