wampserver2.5-Apache-2.4.9-Mysql-5.6.17-php5.5.12-32b搭建php環境
在win下,下載wampserver2.5-ApacheMy-2.4.9-My-5.6.17sql php5.5.12-32b.exe,預設安裝。
然後開啟安裝目錄下apache的httpd.conf設定檔D:wampbinapacheapache2.4.9confhttpd.conf
修改如下:
<span> 1</span> Listen 0.0.0.0:8088 <span> 2</span> Listen [::0]:8088 <span> 3</span><span> 4</span> ServerName localhost:8088 <span> 5</span><span> 6</span> DocumentRoot "D:/kkkoffice/wwwroot" <span> 7</span><span> 8</span> <directory></directory> <span> 9</span><span>#</span><span>AllowOverride none</span><span>10</span><span>#</span><span>Require all denied</span><span>11</span><span> Options FollowSymLinks </span><span>12</span><span> AllowOverride None </span><span>13</span> Order deny,<span>allow </span><span>14</span><span>#</span><span>Deny from all</span><span>15</span><span> allow from all </span><span>16</span> <span>17</span><span>18</span> <directory> <span>19</span><span> Options FollowSymLinks </span><span>20</span><span> AllowOverride None </span><span>21</span> Order deny,<span>allow </span><span>22</span><span> allow from all </span><span>23</span> </directory>
可能出現的問題:造訪http://localhost:8088/phpinfo.php
如果出現
You don't have permission to access /test/file.php on this server 註釋Deny from all all----拒絕所有想存取的httpd.conf都記得要重啟apache
重啟刷新頁面正常訪問如下
好啦,環境已經搭建成功!
以上就介紹了php環境搭建wampserver、Apache、Mysql和php,包含了wampserver,php環境搭建的內容,希望對PHP教學有興趣的朋友有幫助。