[solved]php doesn’t works

Home Page Forums Network Management ZeroShell [solved]php doesn’t works

This topic contains 8 replies, has 0 voices, and was last updated by  odin 2 years, 7 months ago.

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #44542

    odin
    Member

    Php doesn’t seems to work, i tried goind on https://xxx.xxx.xxx.xxx/add-ons/phpinfo.php but it gave me http 404.
    I checked in /var/www/ and phpinfo.php is there.
    Not sure if is a bug or an error i made.

    #54128

    DrmCa
    Participant

    is phpinfo.php under /var/www or under /var/www/add-ons?

    #54129

    odin
    Member

    under /var/www

    #54130

    DrmCa
    Participant

    Then your URL has an extra directory /add-ons

    #54131

    odin
    Member
    #54132

    DrmCa
    Participant

    Can you place a .txt or .html file there and try to access? What would happen?

    You’ll need to check the apache command line, run

    ps lmax |grep httpd

    for any -f key that may override the default config file location. Then check the config file for the apache home directory, it may not be /var/www

    With PHP not working you should not be getting a 404 error. I would expect a PHP file to be served as plain text instead. 404 may mean Apache is using a different directory.

    #54133

    odin
    Member

    I created a txt file, still 404

    this is the output

    5  1000  2522  9360  20   0  6968 2820 -      S    ?          0:00 /usr/local/apache2/bin/httpd -k start
    5 1000 2523 9360 20 0 7100 4716 - S ? 0:00 /usr/local/apache2/bin/httpd -k start
    5 1000 2524 9360 20 0 7100 4776 - S ? 0:00 /usr/local/apache2/bin/httpd -k start
    0 0 7123 598 20 0 2272 580 - S pts/0 0:00 grep httpd
    1 0 9360 1 20 0 6836 4880 - S ? 0:00 /usr/local/apache2/bin/httpd -k start
    5 1000 9363 9360 20 0 7104 4868 - S ? 0:00 /usr/local/apache2/bin/httpd -k start
    5 1000 9364 9360 20 0 7096 4916 - S ? 0:00 /usr/local/apache2/bin/httpd -k start
    5 1000 9367 9360 20 0 7104 4748 - S ? 0:00 /usr/local/apache2/bin/httpd -k start
    5 1000 11137 9360 20 0 7100 4892 - S ? 0:00 /usr/local/apache2/bin/httpd -k start
    5 1000 11160 9360 20 0 7100 4740 - S ? 0:00 /usr/local/apache2/bin/httpd -k start
    5 1000 11164 9360 20 0 7100 4732 - S ? 0:00 /usr/local/apache2/bin/httpd -k start
    5 1000 11165 9360 20 0 7100 4920 - S ? 0:00 /usr/local/apache2/bin/httpd -k start

    What does it mean the -k?

    #54134

    DrmCa
    Participant

    Your guess is as good as mine in this respect.
    -f key is used to override the default config file IIRC.
    so your installation should be using the default config location

    Can you post the output of

    ls -l /var/www

    #54135

    odin
    Member
    lrwxrwxrwx    1 root     root           29 Apr 19 19:35 /var/www -> /var/register/system/PHP/www/
    #54136

    DrmCa
    Participant

    Oh, it is a symbolic link! Post the output of:

    ls -l /var/register/system/PHP/www/

Viewing 10 posts - 1 through 10 (of 10 total)

You must be logged in to reply to this topic.