Apache serving non-php files as php?

    Date: 04/03/08 (Apache)    Keywords: php, apache

    My server seems to think the following is PHP and serve it as such:

    http://www.perturb.org/tmp/test.php.foo.bar

    However... the same file (symlinked)

    http://www.perturb.org/tmp/test.php.txt

    Is served as text. In fact it appears that apache servers the content as whatever the "last recognizable" extension. Shouldn't apache only server files that END in .php as php files?

    The configuration is very simple:

    AddType application/x-httpd-php .php
    AddType application/x-httpd-php-source .phps

    Source: http://community.livejournal.com/apache/41268.html

« Is it possible in Apache to... || "You don't have... »


antivirus | apache | asp | blogging | browser | bugtracking | cms | crm | css | database | ebay | ecommerce | google | hosting | html | java | jsp | linux | microsoft | mysql | offshore | offshoring | oscommerce | php | postgresql | programming | rss | security | seo | shopping | software | spam | spyware | sql | technology | templates | tracker | virus | web | xml | yahoo | home