skip to Main Content

i have apache2 running as a local server. I had a wordpress site on localhost running happily. In trying to enable running phpMyAdmin apache2 somehow stopped executing php code, and I’ve been unable to re-enable it.
any help most gratefully received

2

Answers


  1. This is a configuration issue.

    There should be a line:

    LoadModule php7_module        modules/libphp7.so. 
    

    And:

    <FilesMatch ".ph(p?|tml)$"> 
         SetHandler application/x-httpd-php 
    </FilesMatch> 
    

    This will configure all files that start with ph. Like .php and .phtml. The handler defines which extension files are processed by PHP.

    If you need to have .html files processed by PHP as well, you can put:

    <FilesMatch ".html)$"> 
         SetHandler application/x-httpd-php 
    </FilesMatch> 
    

    Note that all your .html files would then be processes through the PHP interpreter.

    Login or Signup to reply.
  2. My problem was that I used the Brave Browser. That seemed to be the problem. PHP on apache2 and OpenSuse was working perfectly fine on all other major browsers (Chrome, Firefox, Edge).

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search