Skip to content

Instantly share code, notes, and snippets.

@yiquncode
Created March 9, 2011 07:19
Show Gist options
  • Save yiquncode/861820 to your computer and use it in GitHub Desktop.
Save yiquncode/861820 to your computer and use it in GitHub Desktop.
Fix cpanel master domain
#1.Replace "artidea.me" to your master domain
#2.Replace "blog" to the path that you want via through "www.artidea.me"
RewriteCond %{HTTP_HOST} ^(www.)?artidea.me$
RewriteCond %{REQUEST_URI} !^/blog/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /blog/$1
RewriteCond %{HTTP_HOST} ^(www.)?artidea.me$
RewriteRule ^(/)?$ blog/ [L]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment