Apache+php5
生活随笔
收集整理的這篇文章主要介紹了
Apache+php5
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
1.下載回來的是解壓文件,解壓好放到要安裝的位置。(我這里以D:\Acpache24為例) 2.打開Apache24\conf下httpd.conf 文件,用記事本打開即可。 (1)第37行ServerRoot "c:/Apache24"改為ServerRoot “D:/Apache24”;//Apache程序的位置。
(2)第204行的ServerAdmin改不改無所謂; (3)第213行ServerName前面的“#”號去掉; (4)第237行DocumentRoot "c:/Apache24/htdocs"改為DocumentRoot "D:/www";//網站的根目錄
第238行<Directory "c:/Apache24/htdocs">改為<Directory " D:/www ">; 注意:這個WWW文件夾要自己去新建的,不建的話會報錯的。 (5)第271行DirectoryIndex index.html改為DirectoryIndex index.html index.php index.htm //支持更多的默認頁
(6)第354行 ScriptAlias /cgi-bin/ "c:/Apache24/cgi-bin/"改為ScriptAlias /cgi-bin/ "d:/Apache24/cgi-bin/" (7)第370行<Directory "c:/Apache24/cgi-bin">改為<Directory "D:/Apache24/cgi-bin">
安裝到服務里
這里加入服務的命令為:httpd.exe -k install -n "servicename"裝載PHP模塊
# php5 support LoadModule php5_module "d:/php/php5apache2_4.dll" AddHandler application/x-httpd-php .php # configure the path to php.ini PHPIniDir "d:/php"?
轉載于:https://www.cnblogs.com/flyfish2012/p/3750874.html
總結
以上是生活随笔為你收集整理的Apache+php5的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: python django 模板
- 下一篇: php xml 互相转换