PHP not invoked when DocumentRoot directive is added

Discussion in 'General' started by Spawnsworth, Sep 19, 2019.

  1. Spawnsworth

    Spawnsworth Member


    I have a strange problem with a website I am migrating from an old server. I've updated to the latest ISP Config version 3.1.15. When I add the new site and select PHP 5.6 (which I installed separately from the Default 7.2), I place an info.php file in the webroot which by default is:


    When I call this in my browser, it gives me the PHP info that I would expect to see, so it works.

    However, if I change my document root to be a couple of dirs lower, it no longer invokes PHP and instead displays the contents of the info.php file in text format.

    So by adding the following Apache directive to options:
    DocumentRoot /var/www/

    Then browsing to:

    My browser displays the following:


    // Show all information, defaults to INFO_ALL



    But it should display the PHP information instead. Any ideas why this is happening just by changing the Document root? Thanks!
  2. Spawnsworth

    Spawnsworth Member

    Hi all,

    I found the solution to this after bouncing around the forums. The correct apache directive would be thus:

    DocumentRoot "{DOCROOT_CLIENT}/www/public"

    till likes this.

Share This Page