822,722 members
Join DaniWeb
Member Log In
Editorial
Hardware & Software
Software Development
Web Development
Internet Marketing
Business Exchange
Community Center
Web Development
>
PHP
> PHP interpret all extensions
Ad:
PHP
Discussion Thread
Unsolved
Views:
30
Similar Threads
extension php_zip.dll causing php to fail on start
in PHP
PHP not working on Windows XP
in PHP
PHP, MySql & IIS Issue
in PHP
Does anyone know how to use the eval function?
in PHP
Smart URL's
in PHP
Permalink
Jul 28th, 2010
0
PHP interpret all extensions
Expand Post »
Hey,
Is there a way to get Apache to interpret all files with MIME types that are not already defined to PHP?
I've tried
AddType application/x-httpd-php *
Any other ideas?
Tnx,
Sam Rudge
samarudge
Reputation Points:
26
Solved Threads:
29
Posting Whiz
Offline
330 posts
since May 2008
Permalink
Jul 29th, 2010
0
Re: PHP interpret all extensions
Hey.
You can try something like:
text Syntax
(
Toggle Plain Text
)
<FilesMatch ".*(?<!gif|png|jpeg|jpg|js|css|xml)$">
SetHandler application/x-httpd-php
</FilesMatch>
<FilesMatch ".*(?<!gif|png|jpeg|jpg|js|css|xml)$"> SetHandler application/x-httpd-php </FilesMatch>
The extensions list in the regexp are those who should
not
be interpreted as PHP.
Atli
Reputation Points:
93
Solved Threads:
65
Posting Pro
Offline
520 posts
since May 2007
DaniWeb Message
Cancel Changes
The following errors occurred with your submission
Okay
Message:
Posting Quick Reply - Please Wait
Previous Thread in PHP Forum Timeline:
png image problem
Next Thread in PHP Forum Timeline:
URL Rewriting Help!!
Tag Cloud for PHP
access
ajax
apache
array
arrays
button
checkbox
cms
code
compare
count
css
curl
data
data-base
database
date
directory
display
dropdown
drupal
dynamic
edit
email
error
excel
facebook
file
form
forms
forum
framework
function
header
htaccess
html
image
insert
javascript
join
joomla
jquery
ldap
link
list
login
loop
mail
menu
multiple
mysql
mysqlquery
open
pagination
parse
password
pdf
php
php/mysql
phpdevelopment
post
preg_replace
print
problem
query
radio
random
recursion
redirect
refresh
regex
retrieve
script
search
select
server
session
sessions
smtp
soap
sort
source
sql
string
submit
syntax
table
text
tutorial
update
upload
url
user
validation
variable
wamp
web
web-development
wordpress
xml
Log into the DaniWeb community
User Name
Password
Request Lost username / password
About Us
|
Contact Us
|
Advertise
|
Acceptable Use Policy
Build Custom RSS Feed
Follow us on
© 2010 DaniWeb® LLC