0
我昨天购买了一个PHP版本5.3.3的虚拟专用服务器 然后我升级了我的php版本到5.4.22 现在htaccess不能正常工作..它不会任何东西。 我的尝试: 我做这在我的httpd.conf.htaccess在php升级后不工作
<Directory />
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
,并没有工作,所以我在我的.htaccess试过这样:
而且这也不管用。 如果我创建一个页面<?php phpinfo() ?>
,我检查加载的模块,我看到mod_rewrite加载。
我的.htaccess
<FilesMatch "\.(htaccess|htpasswd|ini|log|sh|inc|bak)$">
Order Allow,Deny
Deny from all
</FilesMatch>
RewriteEngine on
RewriteRule ^d/(.*)$ delete.php?img=$1 [L]
RewriteRule ^i/(.*)$ i.php?img=$1 [L]
RewriteRule ^e/(.*)$ editor.php?img=$1 [L]
RewriteRule ^u/$ /u/index.php?img=$1
RewriteRule ^([a-zA-Z0-9]*)$ getimage.php?image=$1
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} !-f
RewriteRule \.(gif|jpeg|png|bmp|jpg) http://(ip)/6j5o [NC,L]
ErrorDocument 400 http://(ip)/404.php
ErrorDocument 401 http://(ip)/404.php
ErrorDocument 403 http://(ip)/404.php
ErrorDocument 404 http://(ip)/404.php
ErrorDocument 500 http://(ip)/404.php
任何想法? (我的服务器是Centos 6 64bit)
你升级了Apache还是PHP? –
我跟着这个教程:http://www.tecmint.com/install-apache-mysql-php-on-redhat-centos-fedora/和有一个Apache升级,我认为 – user2980638
我可能是错的,但不应该你的目录“标签”有绝对根目录中的完整目录路径吗?例如' ' –
Lee