Hi Dp .. I did a 301 redirection to redirect mysiteexample.com pages to www.mysiteexample.com pages // here is the code .. in the .htaccess <Ifmodule mod_rewrite.c> Options +FollowSymlinks RewriteEngine on RewriteBase / ### re-direct index.php to root / ### RewriteCond %{THE_REQUEST} ^.*\/index\.php\ HTTP/ RewriteRule ^(.*)index\.php$ /$1 [R=301,L] ### re-direct IP address to www ### re-direct non-www to www ### re-direct any parked domain to www of main domain RewriteCond %{http_host} !^www.youtips.net$ [nc] RewriteRule ^(.*)$ http://www.youtips.net/$1 [r=301,nc,L] #### </Ifmodule> PHP: It works fine , but subdomain , blog.mysiteexample.com is redirected to www.mysiteexample.com/blog .. Can anyone help me to fix this ? thanks
Propably you will have to do the same in .htaccess which is in the directory of blog.mysiteexample.com .
RewriteEngine On RewriteCond %{HTTP_HOST} ^domainname.com RewriteRule (.*) http://www.domainname.com$1 [R=301,L] Save this in .htaccess format and upload it to your site, i hope it will work