apache開啟偽靜態(tài)的方法

這篇文章主要為大家詳細(xì)介紹了apache開啟偽靜態(tài)的方法,文中示例代碼介紹的非常詳細(xì),具有一定的參考價(jià)值,感興趣的小伙伴們可以參考一下。?
apache開啟偽靜態(tài)的步驟:?
打開apache的配置文件httpd.conf,路徑:wamp\bin\apache\apache2.4.9\conf\httpd.conf?
找到?
?#LoadModule rewrite_module modules/mod_rewrite.so把前面#去掉。沒有則添加,但必選獨(dú)占一行,使apache支持?mod_rewrite?模塊?
找到?
<Directory "D:/ApacheServer/web"> ???# ???# Possible values for the Options directive are "None", "All", ???# or any combination of: ???# ??Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews ???# ???# Note that "MultiViews" must be named *explicitly* --- "Options All" ???# doesn't give it to you. ???# ???# The Options directive is both complicated and important. ?Please see ???# core.html ???# for more information. ???# ???Options Indexes FollowSymLinks ????# ???# AllowOverride controls what directives may be placed in .htaccess files. ???# It can be "All", "None", or any combination of the keywords: ???# ??Options FileInfo AuthConfig Limit ???# ???AllowOverride None ????# ???# Controls who can get stuff from this server. ???# ???Order allow,deny ???Allow from all </Directory>把?AllowOverride None?換成?AllowOverride All?使apache支持?.htaccess?文件?
重啟apache服務(wù)器?
在要啟用偽靜態(tài)的?PHP?項(xiàng)目根目錄下建立?.htaccess?文件
了解更多網(wǎng)絡(luò)知識(shí)關(guān)注:http://www.vecloud.com/