Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I've got a copy of linux mint 10 (julia). I've got apache2 and php packages installed.

the php5 files are in /etc/apache2/mods-enabled.

Browse to a directory with an 'index.php', and the php file is served up, not executed.

The access log has

127.0.0.1 - - [29/Mar/2011:13:09:40 -0400] "GET /typo3/index.php HTTP/1.1" 200 33147 "-" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.15) Gecko/20110303 Linux Mint/10 (Julia) Firefox/3.6.15"

and the error log has nuthin.

php5.conf contains the following, which would seem to exclude .php, but adding it to the match didn't help.

<IfModule mod_php5.c>
    <FilesMatch "\.ph(p3?|tml)$">
    SetHandler application/x-httpd-php
    </FilesMatch>
    <FilesMatch "\.phps$">
    SetHandler application/x-httpd-php-source
    </FilesMatch>
    # To re-enable php in user directories comment the following lines
    # (from <IfModule ...> to </IfModule>.) Do NOT set it to On as it
    # prevents .htaccess files from disabling it.
    <IfModule mod_userdir.c>
        <Directory /home/*/public_html>
            php_admin_value engine Off
        </Directory>
    </IfModule>
</IfModule>
share|improve this question

1 Answer 1

up vote 1 down vote accepted

The same file on an Ubuntu system I have to hand is

<IfModule mod_php5.c>
  AddType application/x-httpd-php .php .phtml .php3 .php4 .php5 .php
  AddType application/x-httpd-php-source .phps
</IfModule>

you might try and see if that works.

share|improve this answer
    
Bingo! What were the mint people thinking? –  bmargulies Mar 29 '11 at 19:01

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.