I moved to a new host on a dedicated ip and have 2 addon domains. When I go to my ip address my addon domain comes up. Shouldn't the main domain name be the one showing? I'm using hostgator.
Either the main domain should be showing or a holding page for the server or hosting software. Best bet would be to contact hostgator as they're the ones in place to look at what's occurring.
I just spoke to technical support and he told me to go to http://useripaddress/username and the main domain does come up. I wonder why the difference?
Its prob due to the fact that in the virtual hosts setup for apache, the addon domain is listed prior to the main domain, so, when requesting the IP addy, the web server serves up the first site that matches. Just edit the file that contains the virt hosts, and place your main domain first.
If you use cPanel when you create the Addon Domain you must specify a folder for the Domain and by default this directory is /public_html/domainname, but, you can change it to /domainname or /public_domainname for hiding it on the Principal Domain. About the Secondary Addon Domain showing in the root of the Dedicated IP Addr i think you must go here.
You would need root access to change the file itself, on cPanel, it is usually located at: /usr/local/apache/conf/httpd.conf