1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice
  2. Dear Pleskians, please read this carefully! New attachments and other rules Thank you!
    Dismiss Notice
  3. Dear Pleskians, I really hope that you will share your opinion in this Special topic for chatter about Plesk in the Clouds. Thank you!
    Dismiss Notice

php extensions vhost.conf

Discussion in 'Plesk for Linux - 8.x and Older' started by nc001, Mar 16, 2006.

  1. nc001

    nc001 Guest

    0
     
    Hi i want to add an php execution extenstion to an vhost.
    I´ve create a file called:
    /var/www/vhost/xx.xxxxx.xx/conf/vhost.conf
    with the following contents:
    Code:
    <VirtualHost 11.11.11.11:80>
    	<Directory /var/www/vhosts/xxx.xxx.xxx/httpdocs>
    	<IfModule mod_php4.c>
    		AddType text/plain .php .php4 .php3 .phtml .inc
      		php_admin_flag engine off
    	</IfModule>
    	</Directory>
    	<Directory /var/www/vhosts/xxx.xxxx.xxx/web_users>
    	<IfModule mod_php4.c>
    		AddType text/plain .php .php4 .php3 .phtml .inc
    		php_admin_flag engine off
    	</IfModule>
    	</Directory>
    </VirtualHost>
    
    
    
    If added .inc as you can see, but it wont work. :(
    It would be cool if anybody could help me!
    Thx
     
  2. eilko

    eilko Regular Pleskian

    28
    73%
    Joined:
    Aug 1, 2001
    Messages:
    468
    Likes Received:
    4
    Location:
    Enschede, Netherlands
    what are you trying to do? should the .inc be seen as a php-file or not?

    If not, why not just disable php for a domain in Plesk? Then .php and .inc are just text files

    if yes, why do you turn of the php-engine in your statement?

    According to my httpd.conf the correct type for php files seems to be AddType application/x-httpd-php and not text/plain
     
  3. nc001

    nc001 Guest

    0
     
    This is how the httpd.include in the directory (subdomain) looks like.
    I copied the content into vhost.conf and just added .inc to the line.
    cat http.include > vhost.conf
    But PHP works fine. Just the inc´s are not parsed "*compiled*" by php.
     
  4. eilko

    eilko Regular Pleskian

    28
    73%
    Joined:
    Aug 1, 2001
    Messages:
    468
    Likes Received:
    4
    Location:
    Enschede, Netherlands
    run /usr/local/psa/admin/sbin/websrvmng --reconfigure-vhost --vhost-name=<domain_name>

    and then restart apache
     
Loading...