• MySQL 4.1.x及以上
• php 4.3.x及以上
• WebServer (Apache 1.3.x或2.0.x及以上,IIS 3及以上,等等)
•Xampp集成了MySQL、php和Apache,所以我们可以直接下载Xampp
•第一步:安装xampp
•第二步:启动xampp前先检查apache和mysql的端口是否已被占用,其中apache需要端口80和443,mysql需要3306端口
netstat –ano –查看端口的时候情况
Proto Local Address Foreign Address State PID
TCP 0.0.0.0:80 0.0.0.0:0 LISTENING 264
netstat -ano|findstr "264“ –查看pid为“264”的程序所占用的端口
TCP 0.0.0.0:80 0.0.0.0:0 LISTENING 264
•端口被占用的解决办法:
1.kill掉占用该端口的程序或服务
2.修改apache、mysql需要的端口号,xampp\apache\conf\httpd.conf
•第三步:测试apache,点击apache_start.bat
•报错:Apache konnte nicht gestartet werden
Apache could not be started
Apache could not be started
•查看apache的error.log:错误信息如下
• Attempt to reload DynaLoader.pm aborted.
•Compilation failed in require at C:/xampp/perl/site/lib/ModPerl/Const.pm line 18.
•BEGIN failed–compilation aborted at C:/xampp/perl/site/lib/ModPerl/Const.pm line 18.\nCompilation failed in require at C:/xampp/perl/site/lib/Apache2/Const.pm line 18.
•BEGIN failed–compilation aborted at C:/xampp/perl/site/lib/Apache2/Const.pm line 18.
•Compilation failed in require at /xampp/apache/conf/extra/startup.pl line 9.
•BEGIN failed–compilation aborted at /xampp/apache/conf/extra/startup.pl line 9.
•Compilation failed in require at (eval 2) line 1.
错误原因:windows 2003的主机上已安装过oracle 10g,perl的变量与xampp的perl变量冲突
解决办法:
系统环境变量里的PERL5LIB环境变量的值修改一下,在前面加上xampp的perl加载环境变量
C:\xampp\perl\lib;C:\xampp\perl\site\lib;(一定要加在前面)
成功后点击,apche_stop.bat停止apache
•点击xmapp-control
•第四步:为MYSQL设置密码;打开IE浏览器;输入
http://127.0.0.1/xampp;进入页面,选择中文;
•进入XAMPP配置页面;选择【安全】列表,在点击右侧链接;
![](http://blog.mchz.com.cn/wp-content/uploads/1%2841%29.png)
![](http://blog.mchz.com.cn/wp-content/uploads/2%2820%29.png)