Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Removing alias breaks the website

Discussion in 'General Discussion' started by BluePlanet, Sep 8, 2018.

Tags:
  1. BluePlanet

    BluePlanet Member

    Joined:
    Apr 29, 2018
    Messages:
    13
    Likes Received:
    1
    Trophy Points:
    3
    Location:
    Egypt
    cPanel Access Level:
    Root Administrator
    Hi all,

    I created a cPanel with the customer domain name website.com
    I built the website on a temporary URL, like customer.mydomain.com, which is assigned as an alias, with no redirection-
    Whilst the site sits on the temporary URL, the customer can customize it and keep the previous website live.
    When the customer is ready, he will redirect his domain name to my server IP. Once DNS have propagated and the site is live, I go and remove the alias.

    At this point, the live website breaks. I've had this 2 times and can't figure out why.
    From the browser's console, it would appear it is not loading any of the .js files.
    Any help, please.
     
    #1 BluePlanet, Sep 8, 2018
    Last edited: Sep 8, 2018
  2. 24x7server

    24x7server Well-Known Member

    Joined:
    Apr 17, 2013
    Messages:
    1,890
    Likes Received:
    91
    Trophy Points:
    78
    Location:
    India
    cPanel Access Level:
    Root Administrator
    Hi,

    Are you adding the customer domain as subdomain?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
    BluePlanet likes this.
  3. BluePlanet

    BluePlanet Member

    Joined:
    Apr 29, 2018
    Messages:
    13
    Likes Received:
    1
    Trophy Points:
    3
    Location:
    Egypt
    cPanel Access Level:
    Root Administrator
    Thank you, it was added just an alias, not as subdomain.
    It was also not redirected anywhere. It was just an additional domain, where the website was available till it would go live.

    I solved with a redirection on the .htaccess file
     
  4. cPanelMichael

    cPanelMichael Technical Support Community Manager Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    47,555
    Likes Received:
    2,182
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello @BluePlanet,

    Does the website use an application such as WordPress? If so, browse to the administration area of the application installed on the website and ensure it's properly configured to reflect the correct domain name.

    To test if this is the culprit, upload a simple HTML file in the document root of the website and confirm if it loads.

    Thank you.
     
    BluePlanet likes this.
  5. BluePlanet

    BluePlanet Member

    Joined:
    Apr 29, 2018
    Messages:
    13
    Likes Received:
    1
    Trophy Points:
    3
    Location:
    Egypt
    cPanel Access Level:
    Root Administrator
    Many thanks @cPanelMichael
    the website uses a proprietary code, developed in PHP. The entire CMS folder and its subfolder required to be redirect through .htaccess
    What I find interesting is that the situation occurs only when I remove the (non-redirected) alias.
    If I create a new cPanel account using the alias as domain and then replace it with the customer domain, when he is ready to go live, then everything is fine.

    Also, if I delete all the content of /public_html and upload the standard content again, it all works fine, even without any redirection on .htaccess
     
    #5 BluePlanet, Sep 16, 2018
    Last edited: Sep 16, 2018
  6. cPanelMichael

    cPanelMichael Technical Support Community Manager Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    47,555
    Likes Received:
    2,182
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello @BluePlanet,

    Can you open a support ticket so we can take a closer look and see what's happening on the actual domain name and alias? You can post the ticket number here and we will link this thread to it.

    Thank you.
     
    BluePlanet likes this.
  7. BluePlanet

    BluePlanet Member

    Joined:
    Apr 29, 2018
    Messages:
    13
    Likes Received:
    1
    Trophy Points:
    3
    Location:
    Egypt
    cPanel Access Level:
    Root Administrator
    Absolutely @cPanelMichael glad to see this level of support and engagement!

    On the website where the issue occurred, we already fixed the situation, with an .htaccess redirect.

    Would you like me to build a dummy site, apply an alias and then remove it? So you can see from the console what errors are returned when the alias is removed. Please let me know, tnx.
     
    #7 BluePlanet, Sep 17, 2018
    Last edited: Sep 17, 2018
  8. cPanelMichael

    cPanelMichael Technical Support Community Manager Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    47,555
    Likes Received:
    2,182
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello @BluePlanet,

    Can you do this, and let us know the full step-by-step instructions you use to reproduce the issue?

    Thank you.
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice