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'm facing a strange issue with a fresh installed ubuntu 13.10 apache2 with mysql and php. My php won't get parsed and I have been doing every changes what I found during my researches

PHP 5.5.3-1ubuntu2 (cli) (built: Oct  9 2013 14:49:12) 

sudo a2enmod php5


<FilesMatch \.php$>
    SetHandler application/x-httpd-php

<Directory /var/www/>
        Options Indexes FollowSymLinks
        AllowOverride All
        Require all granted


# Deny access to files without filename (e.g. '.php')
<FilesMatch "^\.ph(p[345]?|t|tml|ps)$">
    Order Deny,Allow
    Deny from all

# Running PHP scripts in user directories is disabled by default
# 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>
share|improve this question
You reloaded Apache since your sudo a2enmod php5 command, right? –  Capsule Oct 22 '13 at 9:50
yes I do, still raw php in browser! –  fefe Oct 22 '13 at 9:54
check what's the parent directive of the SetHandler one in apache2.conf (ie, is it server wide or directory specific). I'm also surprised to see php directives in the main apache config file, they should only be present in the php5.conf file. –  Capsule Oct 22 '13 at 10:05
okay solved problem php.ini short tags needs to be enabled. sorry for not seeing this –  fefe Oct 22 '13 at 10:48
add comment

Your Answer


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

Browse other questions tagged or ask your own question.