views:

20

answers:

1

Hi, I am currently struggling with the following problem.

I have successfully installed Apache2 and PHP5. And it works until I change the DocumentRoot of the Apache2 to something different than /var/www.

I want to set the DocumentRoot to /home//wwwroot, but after doing this all php pages are just white. (no download message or sth.)

Here is my php5.conf:

<IfModule mod_php5.c>
   AddType application/x-httpd-php .php .phtml .php3
   AddType application/x-httpd-php-source .phps
#    <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>

I dont get it, and need help.

Thx!

A: 

Try this instead. Don't use AddType, as that breaks content negotiation.

LoadModule ...
<IfModule php5_module>
    #PHPIniDir "/whatever/"

    AddType text/html .php .phps
    AddHandler application/x-httpd-php .php
    AddHandler application/x-httpd-php-source .phps

    <Directory /home/*/public_html>
        php_admin_value engine Off
    </Directory>
</IfModule>
Artefacto
I tried it, but no difference. Is #PHPIniDir important? Its a comment right?