The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Addon domain auto redirects

Discussion in 'General Discussion' started by kaidok.net, May 25, 2008.

  1. kaidok.net

    kaidok.net Member

    Joined:
    Mar 7, 2005
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    1
    I have setup an addon domain and during the process it automatically setup a subdomain and did a redirect to it.

    I want the add-on domain to not redirect. I want to just pull it up in the browser with the add-on domain in the address bar but instead it shows the subdomain.
     
  2. thewebhosting

    thewebhosting Well-Known Member

    Joined:
    May 9, 2008
    Messages:
    1,201
    Likes Received:
    1
    Trophy Points:
    38
    This is how add-on domain feature works. If you wish to host an entirely new site on the current hosted domain then it will do below things....

    1) Create newdirectory
    2) Setup a pointer to newdirectory.olddomain.com
    3) Setup a pointer to http://www.newdomain.com

    Now, anything you will upload into newdirectory can be viewed by going to both http://www.newdomain.com and http://newdirectory.olddomain.com.
     
  3. kaidok.net

    kaidok.net Member

    Joined:
    Mar 7, 2005
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    1
    Ok. But one problem we are running into is that if we navigate to http://domain.com the page is blank or shows a place holder for an unfound image. If I go to http://subdomain.domain.com the site works perfectly fine. If I "view source" from my browser the html is exactly the same but it is not displaying.

    Has anyone ever seen this before. It is rather strange that the page is not functioning right from the add-on domain URL. It is a simple html page with 1 image in it.
     
  4. cPanelDavidG

    cPanelDavidG Technical Product Specialist

    Joined:
    Nov 29, 2006
    Messages:
    11,279
    Likes Received:
    8
    Trophy Points:
    38
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    In my experience, this is caused by a X/HTML or CSS coding error. Usually caused by the X/HTML or CSS not being built with portability in mind.
     
  5. kaidok.net

    kaidok.net Member

    Joined:
    Mar 7, 2005
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    1
    Thanks David. I will look into that.
     
  6. kaidok.net

    kaidok.net Member

    Joined:
    Mar 7, 2005
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    1
    Well that seemed to be one piece of it. Now at least I get a placeholder that is the same size as the image and the image mapping is active but no image. Here is the code, as you can see it is the most basic it could be. I have tried the link to the images as the actual URL path and as ./images/main.JPG. Both produce the exact same thing.

    edit: I just found out that if you go to http://heatherdmcgee.cultofnot.com and then http://heatherdmcgee.com the image shows up , but if you hit f5 the image reverts back to a placeholder. This seems like very odd behavior.


    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
    <title>Untitled Document</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    </head>
    
    <body>
    <img src="http://heatherdmcgee.com/images/main.JPG" width="626" height="511" hspace="300" vspace="0" border="0" usemap="#Map"> 
    <map name="Map">
      <area shape="rect" coords="515,11,585,56" href="http://heatherdmcgee.com/about.htm" target="_self">
    </map>
    </body>
    </html>
     
    #6 kaidok.net, May 28, 2008
    Last edited: May 28, 2008
  7. cPanelDavidG

    cPanelDavidG Technical Product Specialist

    Joined:
    Nov 29, 2006
    Messages:
    11,279
    Likes Received:
    8
    Trophy Points:
    38
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    Both pages work equally well for me (image displays etc.). What you describe is indicative of a client-side issue. You may wish to consider clearing your cache.
     
  8. kaidok.net

    kaidok.net Member

    Joined:
    Mar 7, 2005
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    1
    I know it is not client side as I have tried with 3 different PC's and all produce the same result. When you went to the domain, rather than the subdomain, did you press f5 and refresh it? When I do on all three machines the image changes to a place holder.
     
  9. cPanelDavidG

    cPanelDavidG Technical Product Specialist

    Joined:
    Nov 29, 2006
    Messages:
    11,279
    Likes Received:
    8
    Trophy Points:
    38
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    Odd, the image on the page: http://heatherdmcgee.com/images/main.JPG

    ... generates a HTTP 403. Are you using hotlink protection by chance?
     
  10. kaidok.net

    kaidok.net Member

    Joined:
    Mar 7, 2005
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    1
    David, you're a genious. I would not have even thought that. The customer did have it turned on so I added the domain to the allowed referers and viola, problem fixed.

    Thanks a bunch to you and all of the Cpanel folks. You guys have been great.
     
Loading...

Share This Page