Home  >  Article  >  php教程  >  Windows下部署Apache+PHP+MySQL运行环境实战

Windows下部署Apache+PHP+MySQL运行环境实战

WBOY
WBOYOriginal
2016-06-13 11:58:10926browse

官方下载地址:
MySQL http://www.mysql.com/downloads/mysql/ 找个MSI文件下下来.Apache http://httpd.apache.org/download.cgi
Php http://windows.php.net/download/#php-5.4

首先是MySQL,(这边吐槽一下被Oracle收购的MySQL)

一步一步往下,无需更多的配置

然后安装Apache,

也是一步一步往下

安装PHP,(我偷懒我自豪, 在PHP下载页面找那个Installer的文件.......吐槽可能不是最新的版本= =~)

下载页面

安装注意

其他要记住的:

其实上面的都是扯皮,下面的才是我想记的

1.PHP和IIS结合注意

 在IIS Manager编辑这个值

2.PHP和Apache结合,Apache的config文件改动

在C:\Program Files\Apache Software Foundation\Apache2.2\conf\httpd.conf 添加

复制代码 代码如下:


PHPIniDir "D:\Program Files\PHP\"
LoadModule php5_module "D:\Program Files\PHP\php5apache2_2.dll"


3.Apache的config设置到workspace (方便Eclipse调试)

 在C:\Program Files\Apache Software Foundation\Apache2.2\conf\httpd.conf 修改

复制代码 代码如下:


DocumentRoot "D:\workspaces"

......


4.设置PHP的默认编码

在C:\Program Files\PHP\php.ini添加修改成

default_charset = "gb2312" 
如果大家感觉配置麻烦,可以用phpnow或apmsevr快速搭建php运行环境
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn