Adding A Second Website Using PowWeb’s ‘Map to Subdirectory Tool’

May 8th, 2007

Previously, I was using a .htaccess code to redirect my second domain name to the subfolder where I uploaded my second website. But then I found out that it is not possible to upload a second or third website to a folder unless it is a subfolder of your home/htdocs folder. That means that it is possible for my visitors to access my second website using my first website URL.

Let’s say my first website is on home/htdocs folder and can be accessed on the url www.first-domain-name.com and my second website is on the directory home/htdocs/secondwebsite/. This means that if my first website’s visitors would go to www.first-domain-name.com/secondwebsite, they will see my second website which is completely different from the first one. This is because my first and second website are both pointing to the htdocs and I just use a htaccess to redirect my second domain to a subfolder inside it.

I would experience problems in the future if I want my 2nd, 3rd, and fourth websites, to be distinct and different from each other, especially if they are specifically intended for different companies or group of people.

To solve this problem, I searched PowWeb Forum and one thread suggested the use of a “Map to Sub Directory Bundle“. The bundle description states that this tool “..is specifically designed for customers who don’t know or are uncertain how to manage tricky .htaccess scripts and other methods to get their directory structure ready for multiple sites on the same account.” The bundle has a fee of $27.77 and comes with a Domain credit.

I purchased the tool and then proceeded to OPS and searched the tab where I can use this tool. I found the tool on the Domains >>> Subdomain Mapping page where it indicates “Full Domain to Subdirectory Mapping”. You will need to enter the exact path where the website was uploaded to. On my case, I want to upload the files for my second website to a subdirectory outside ‘htdocs’, say home/secondwebsite/htdocs. I entered the path ’secondwebsite/htdocs’ on the “Points to Directory” column. I needed to create an ‘htdocs’ folder inside the ’secondwebsite’ for my files to work, otherwise, the 2nd website will just show a “Directory Has No Index File” message. This means that every files that I need on my website should be uploaded on a ‘htdocs’ folder.

Related Articles
Adding A Second Website Using .htaccess

Useful Links
PowWeb OPS
Map To Subdirectory Bundle

PowWeb Forum Links:
How to: Multiple sites on one account

Leave a Comment

You must be logged in to post a comment.