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.

CPanel blatently advertising in your /usr/local/apache/htdocs

Discussion in 'EasyApache' started by porcupine, Mar 20, 2004.

  1. porcupine

    porcupine Well-Known Member
    PartnerNOC

    Joined:
    Apr 18, 2002
    Messages:
    74
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Toronto, Ontario
    cPanel Access Level:
    DataCenter Provider
    Ok, now this is getting quite frustrating and annoying.

    We run private reseller servers, thus people like there to be some sort of placeholder on the main IP/hostname of each server in case the users go to check this. We set this up to go to phpsysinfo, then have links off for phpinfo, etc.

    We used to do this by creating a user, and having it go to that users home directory and setting it up all "officially" as you *think* CPanel's system might prefer. This was not possible though as it would not allow you to add a user with the main hostname of the server. So we would add the user, then modify the account to do this.

    Not so shortly after, CPanel wrote in an error script with a "IF YOU SEE THIS, SOMETHING IS VERY WRONG WITH YOUR SERVER" that appeared whenever the wwwaccts script was run, meaning every time a user modified an account, they'd see that. Needless to say, this created a load of problems, troubletickets, panic'd users, and speculatively lost revenues as some customers saw this as our fault/mis-doing.

    Thus we decided to go the logical route. Being less convinient, we started putting phpsysinfo where it *BELONGS* to do this task, in /usr/local/apache/domlogs.

    Shortly after, I notice that it's no longer being displayed, instead the CPanel "cPanel is a leading provider of software for the webhosting industry. If you would like to learn more about cPanel please visit our website at http://www.cpanel.net/". I deleted their index.html page, yet it keeps coming back. Someone want to clue me in to whats supposed to be going on here? I'm getting sick of changing around our configurations on dozens of servers because of DarkORB's changes (and no, I have no interest in changing the priorities of the index's so .php comes before .html).
     
  2. Marty

    Marty Well-Known Member

    Joined:
    Oct 10, 2001
    Messages:
    630
    Likes Received:
    1
    Trophy Points:
    18
    Put your own index.html file in /usr/local/apache/htdocs and cpanel should not overwrite it. This was discussed before and that was the solution that cpanel implemented.
     
  3. porcupine

    porcupine Well-Known Member
    PartnerNOC

    Joined:
    Apr 18, 2002
    Messages:
    74
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Toronto, Ontario
    cPanel Access Level:
    DataCenter Provider
    Unfortunatly that does little for me.

    An example being:

    http://www2.pcdc.net/index.html
    http://www2.pcdc.net/index.php

    As you can see, this just being a symbolic link, php is not properly parsing its .html symbolically linked file.
     
  4. nickn

    nickn Well-Known Member
    PartnerNOC

    Joined:
    Jun 15, 2003
    Messages:
    619
    Likes Received:
    1
    Trophy Points:
    18
    Keep both the index.html and index.php in the directory, than create a .htaccess with DirectoryIndex index.php

    it's a pain but it works :)
     
  5. dgbaker

    dgbaker Well-Known Member
    PartnerNOC

    Joined:
    Sep 20, 2002
    Messages:
    2,578
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    Toronto, Ontario Canada
    cPanel Access Level:
    DataCenter Provider
    Another option is do not use /usr/apache/htdocs as the default docroot. You can change this to point anywhere you want, then cPanel can do what ever they like with that directory,
     
  6. porcupine

    porcupine Well-Known Member
    PartnerNOC

    Joined:
    Apr 18, 2002
    Messages:
    74
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Toronto, Ontario
    cPanel Access Level:
    DataCenter Provider
    Both are excellent points. Is there any official DarkORB way of doing this (eg. has anyone asked DarkORB) so we dont run around implamenting another "fix" to have it break again for the third time in a row? :)
     
Loading...

Share This Page