UBB.Dev
I've added these lines to my .htaccess file:

<Files blah>
ForceType application/x-httpd-php
</Files>

It does not work. The php-file "blah" is sent to the browser as plain text. I know there's a setting in the httpd.conf "AllowOverride", which has to be set to "All". But I'm on a shared server, so I do not have access to the httpd.conf.

Is there any other way to force a file type to be treated as php script?
There is a way around it by using a custom 404 page(a script)
Read http://www.vbulletin.com/forum/showthread.php?p=133779&mode=linear#post133779

I am using this method here:
http://www.shroomery.org/books/
You may have to check and make sure that the tags are allowed for the script you are using if the apache server does not recognize the script as PHP it will tell the page to display as text I think. In any event if PHP is not on the server then it wont matter what you do it wont parse as anything other than text or a download. you might have to change the file extension to php3, php4 or some other name. This may be something to contact your host about.
Is it an apache server at all?
[] I know there's a setting in the httpd.conf "AllowOverride", which has to be set to "All". [/]
indicates it is an apache server unless httpd.conf is used as the config file on other web servers as well?
You´re right, I missed that detail.
Thanks for the hints so far, I'll try the 404 page-solution if I can find some more time...
Hello,
I had a similar problem, and it took me hours to figure out. When I installed PHP 4.3.4, it inserted this line in my httpd.conf:
AddType application/x-http-php .php
Instead of processing my php files, the source was sent to the browser. After extensive googling, I discovered that the line should be "application/x-httpd-php". So, try it without the 'd'. That must be correct for some systems, or it wouldn't be the default.

(I was installing as a module on Apache 2.0.48 under YellowDog Linux.)
© UBB.Developers