当前位置: 首页 > 图文教程 > 操作系统 > Windows > Windows XP上安装配置 Apache+PHP+Mysql+Zend

Windows
Windows Server 2008关闭闲置状态的IDE通道
Windows Server 2008网络中禁止迅雷下载
Windows Server 2008病毒偷改账号的安全隐患
Windows Server 2008网上邻居打开慢的解决
Windows Server 2008 四项优化技巧
解决Windows Server 2008 回收站无法清空故障
部署RemoteApp实现应用程序的远程调用
Windows Server 2008 R2新增功能概览
Windows Server 2008 WDS 设置完全攻略
卷影复制 解决Windows Server 2008共享隐患
在Windows Server 2008中实现流量的监控和限制
Windows Server 2008的NPS策略应用
巧妙查看Windows Server 2008运行性能
利用命令行 提升Windows Server 2008管理效率
详述Windows Server 2008全面审核策略
配置Windows Server 2008防火墙让系统更安全
你所不知道的Windows7企业功能详解
Windows Server 2008服务器管理控制台解析
活用Windows Server 2008命令 解决网络疑难杂症
定制Windows 2008使它适合日常使用

Windows XP上安装配置 Apache+PHP+Mysql+Zend


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2010-01-16   浏览: 401 ::
收藏到网摘: n/a

所需软件:
apache_2.0.58-win32-x86-no_ssl.msi >>>>>>>>>>>>>>http://archive.apache.org/dist/httpd/ 各个版本都有
php-5.1.6-Win32.zip
ZendStudioServer-5.1.0a-Windows-i386.exe
mysql-5.0.19-win32
phpMyAdmin-2.9.1

安装
Apahce+PHP+MySQL安装配置
1. 安装apache_2.0.58-win32-x86-no_ssl ,根据需要按提示设置程序安装路径(我的路径是d:/usr/)。安装完成以后,如果对APACHE目录进行移动,那么apache2下面的参数是必须改的, 修改apache配置目录CONF下的配置文件httpd.conf,本例为d:/usr/apache2/conf/httpd.conf
(1)ServerRoot:apche的程序目录(本例是d:/usr/apache2)
(2)ServerAdmin:服务器管理员的E-MAIL
(3)port:服务端口,默认80
(4)ServerName:计算机的网络标识,必须和实际一致,否则可能会出现一些想不到的问题
(5)DocumentRoot:默认的网页文件目录(本例是d:/usr/www)
(6)DirectoryIndex:默认页面,添加 php支持,(本例如下)
DirectoryIndex index.html index.htm index.php index.php3 index.php4
(7)ScriptAlias(脚本别名),CGI程序的目录
ScriptAlias /cgi-bin “d:/usr/apache2/cgi-bin”
2. 安装php-5.1.6-Win32解压,解压的路径自定义(本例为d:/usr/php5)。
3. 配置PHP和Apache,使之能解析php程序。
PHP配置:
将PHP目录中的“php.ini-dist”改名“php.ini”,并对
php.ini修改如下:
(1) doc_root:和APACHE的HTDOCS一致,本例为d:/usr/www
(2) extension_dir 本例为 d:/usr/php5/ext
(3) include_path 本例为d:/usr/php5/includes
(4) 去掉extension=php_mysql.dll前边的分号,并拷贝php目录下的LIBMYSQL.DLL文件到c:\winnt\system32下
Apache配置:
在APACHE配置文件最后添加以下语句,用以支持php程序:
ADDlanguage zh-cn .cn
defaultlanguage zh-cn
AddDefaultCharset GB2312
ScriptAlias /php/ "d:/usr/php5/"
LoadFile d:/usr/php5/php5ts.dll
LoadModule php5_module d:/usr/php5/php5apache2.dll
PHPINIDir d:/usr/php5/php.ini
AddType application/x-httpd-php .php .php3 .php4 .phtml
AddType application/x-httpd-php-source .phps
以上添加内容目录部分和实际不一致的自行修改
4.重新启动Apache服务器,用编辑器编写如下语句:
<?
phpinfo();
?>;
保存文件名为“test.php”到用户主目录(本例为d:/usr/www)目录,然后打开浏览器,浏览:http://localhost/test.php,出现PHP基本信息就说明配置成功。
5. 安装MySQL-5.0.19-win,一直按”next”就安装成功了,然后在C:\mysql\bin目录执行” winmysqladmin.exe”,出现mysql的初始信息面,表示安装成功。
6、安装phpMyAdmin
解压phpMyAdmin-2.6.0-pl2.zip到一目录,本例为d:/usr/phpMyAdmin,进入该目录配置文件config.inc.php
修改$cfg['PmaAbsoluteUri']为http://localhost/phpMyAdmin
修改$cfg['blowfish_secret'] = 'admin';
修改$cfg['Servers'][$i]['auth_type']= 'cookie';
修改$cfg['Servers'][$i]['user']为MySQL用户
修改$cfg['Servers'][$i]['password']为MySQL口令
以上是phpMyAdmin配置的基本内容,其他配置根据需要进行
编辑apache配置文件httpd.conf在最后加入以下语句:
php_admin_flag engine on
php_admin_flag safe_mode off
Alias /phpMyAdmin "d:/usr/phpMyAdmin"
;
DirectoryIndex index.php
Options Indexes MultiViews
AllowOverride None
Order allow,deny
Allow from all
php_admin_flag engine on
php_admin_flag safe_mode off
php_admin_value open_basedir none
php_admin_value open_basedir "d:/usr/phpMyAdmin"
;
以上目录路径部分根据实际需要进行修改。
7、测试apache+php+mysql
在ie地址栏输入http://localhost/phpMyAdmin如果出现phpMyAdmin信息说明配置成功。
8、最后安装ZendStudioServer-5.1.0a-Windows-i386.exe