Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save willboudle/4ebe28ed6db875ea8341 to your computer and use it in GitHub Desktop.

Select an option

Save willboudle/4ebe28ed6db875ea8341 to your computer and use it in GitHub Desktop.
Issue :
How to point a parked domain to a sub-directory of the main domain without any change in the URL ?
Fix :
This is like making the parked domain function like an add-on domain.
Assuming that the parked domain name is abc.com and the corresponding folder under the main domain is ‘abc’ .This can be achieved by putting the following in the .htaccess file for the main domain :
RewriteEngine On
Options +FollowSymlinks
RewriteBase /
RewriteCond %{HTTP_HOST} abc.com
RewriteCond %{REQUEST_URI} !abc/
RewriteRule ^(.*)$ abc/$1 [L]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment