Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

I recently upgraded my hosting account to Deluxe where I can host multiple websites. I added a domain name and created a folder in the root directory giving it the same name as my domain name and uploaded my files. Now when I navigate the site the address bar shows:

'http://mywebsite.com/mywebsite/default.aspx'

I want it to display:

'http://mywebsite.com/default.aspx'

My thinking in creating folders that match the domain names is to keep them somewhat organized; never intended to have my domain names listed twice in the address bar.

share|improve this question
    
I have the same issue and I've contacted support about this multiple times. Looks like the only way out is rewriting your URLs, because the second URL you provided there actually works (at least it works for me) –  Maxim Zaslavsky Dec 30 '10 at 20:29
    
You should just switch to a better web host that uses cPanel. Then you can tell the web server which directory to serve your application from. –  Lèse majesté Dec 30 '10 at 23:04
1  
I have exactly the same thing with my sites I host on GoDaddy. I've complained but there's nothing they're able to do about it. The only answer as I understand is to get a dedicated or semi-dedicated server that allows you to handle multiple domains the right way. –  Jonathan Wood Dec 31 '10 at 3:29
2  
Why would you spend more money with a problematic web host? Most web hosts these days use cPanel and allow you to specify the document root for each domain. You don't need to get a dedicated server for that. This is a very basic and useful functionality. If your web host doesn't provide it, then drop them and get a new one. –  Lèse majesté Dec 31 '10 at 8:49
add comment

2 Answers 2

there is a feature called addon domain or parked domain on most hosting panels which in the first case you simply serve other domains to their own respected root folders on one hosting panel.
the parked domain lets you map a domain on a subdomain which again has its own root folder.

share|improve this answer
add comment

The address bar simply shows the domain its it. If you want it to show something else you have to redirect the browser to where you want it to be.

Since you added a domain, you have to specify where that domain is. Your example is slightly misleading since I only see one domain name. Say you have: maindomain.com and you added *secondary_domain.com*

Then you need to point secondary_domain.com to maindomain.com/secondary_domain

Your hosting provider determines how to control this. Usually there is some kind of control panel, the most popular one being cPanel. In it there is an option called Add-On domains where you specify a domain name and the folder where it is located.

This will make your domains accessible through both paths: secondary_domain.com AND maindomain.com/secondary_domain.

In order to help search engines recognize this is the same domain and not duplicate content you should setup, also through the control panel (or using .htaccess if using Apache), a permanent (301) redirect from maindomain.com/secondary_domain to secondary_domain.com

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.