php -- 配置與安裝

來源:互聯網
上載者:User

標籤:des   style   blog   class   code   c   

1.php與apache安裝路徑

 

2.安裝Apache服務 httpd -k install

開啟關閉重啟服務 http -k start/stop/restart

3.php.ini-development重新命名為 php.ini

4.配置Apache的httpd.conf,關聯php解析器。在最後添加

LoadModule php5_module "F:\APP\IDE\PHP\php5\php5apache2_4.dll"
PHPIniDir "F:\APP\IDE\PHP\php5"

在<IfModule mime_module>裡面添加

AddType application/x-httpd-php .php

5.更改伺服器預設目錄

 1 #DocumentRoot "F:\APP\IDE\PHP\Apache24/htdocs" 2 DocumentRoot "D:\a\php\root" 3 Alias /ap "F:\APP\IDE\PHP\Apache24/htdocs" 4 Alias /test "D:\a\php\test" 5 Alias /temp "D:\a\php\temp" 6  7 <Directory "D:\a\php\root"> 8     Require all granted 9     Options Indexes FollowSymLinks10     AllowOverride None11     Order allow,deny12     Allow from all13     Satisfy all14 </Directory>15 <Directory "D:\a\php\test">16     Require all granted17     Options Indexes FollowSymLinks18     AllowOverride None19     Order allow,deny20     Allow from all21     Satisfy all22 </Directory>23 <Directory "D:\a\php\temp">24     Require all granted25     Options Indexes FollowSymLinks26     AllowOverride None27     Order allow,deny28     Allow from all29     Satisfy all30 </Directory>31 <Directory "F:\APP\IDE\PHP\Apache24/htdocs">32     #33     # Possible values for the Options directive are "None", "All",34     # or any combination of:35     #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews36     #37     # Note that "MultiViews" must be named *explicitly* --- "Options All"38     # doesn‘t give it to you.39     #40     # The Options directive is both complicated and important.  Please see41     # http://httpd.apache.org/docs/2.4/mod/core.html#options42     # for more information.43     #44     Options Indexes FollowSymLinks45 46     #47     # AllowOverride controls what directives may be placed in .htaccess files.48     # It can be "All", "None", or any combination of the keywords:49     #   AllowOverride FileInfo AuthConfig Limit50     #51     AllowOverride None52 53     #54     # Controls who can get stuff from this server.55     #56     Require all granted57 </Directory>

 

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.