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!

Problem locating php file on account

Discussion in 'General Discussion' started by dxvvid, Feb 15, 2018.

  1. dxvvid

    dxvvid Registered

    Joined:
    Feb 15, 2018
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Australia
    cPanel Access Level:
    Website Owner
    Hi, I had a .php file that is used for my Contact page for my website. I'm trying to edit the text however I cannot find the .php file anywhere in File Manager to edit it. I tried using greg but it doesn't show the Contact script. Is there another way to locate the .php file thanks!

    My greg php:
    Code:
    <?php
    $command = "grep -ri 'code' ./*";
    $output = shell_exec($command);
    echo "$output";
    echo "Complete.";
    ?>
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    43,903
    Likes Received:
    1,814
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    The default document root for the primary domain name on the cPanel account is:

    /home/username/public_html/

    Thus, if the PHP script you are using is accessed at domain.tld/contact.php, you should find it at /home/username/public_html/contact.php. Note that "username" represents the cPanel username.

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
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