You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Stuart Otway <st...@moveassist.com> on 2002/07/22 16:27:15 UTC

PHP does not work on VirtualHost

hi,

i put it a virtual host into my httpd.conf like so:

<VirtualHost 122.456.789.101:8080>
ServerAdmin me@here.com
DocumentRoot /www/html/myphpap
ServerName 122.456.789.101:8080
ScriptAlias /cgi-bin /www/html/cgi-bin
ErrorLog logs/myap-error.log
CustomLog logs/myap-access.log common
</VirtualHost>

it just displays php as text? can i not run php on a virtual host? it
ran fine when it was on the default server (DocumentRoot
"/www/html/myphpap") but when i move it over it reads the php like text.

Any help or advice would be great.

thanks
stu


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: PHP does not work on VirtualHost

Posted by Jonathan <jo...@driftwood.net>.
you have to map it for Apache to run it.  like:

         AddType application/x-httpd-php .php

jonathan




At 09:27 AM 7/22/2002, Stuart Otway wrote:
>hi,
>
>i put it a virtual host into my httpd.conf like so:
>
><VirtualHost 122.456.789.101:8080>
>ServerAdmin me@here.com
>DocumentRoot /www/html/myphpap
>ServerName 122.456.789.101:8080
>ScriptAlias /cgi-bin /www/html/cgi-bin
>ErrorLog logs/myap-error.log
>CustomLog logs/myap-access.log common
></VirtualHost>
>
>it just displays php as text? can i not run php on a virtual host? it
>ran fine when it was on the default server (DocumentRoot
>"/www/html/myphpap") but when i move it over it reads the php like text.
>
>Any help or advice would be great.
>
>thanks
>stu
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
>For additional commands, e-mail: users-help@httpd.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org