Window下安装Apache2.2+Php5+Mysql+phpmyadmin

php

2009-02-07 21:28

首先下载
-----------------------------------------------------------------------------------------------------------------------
apache2.2
http://tjcnc1.skycn.com/down/apache_2.2.4-win32-x86-no_ssl.zip
PHP5 (压缩包)
http://www.lyzzz.com/uploads/soft/php5.rar
Mysql5.1
http://1.hbwt1.crsky.com/200811/mysql-essential-5.1.30-win32.msi
phpMyAdmin-3.1.2(压缩包)
http://3.tjwt1.crsky.com/200901/phpMyAdmin-3.1.2-all-languages.zip
-----------------------------------------------------------------------------------------------------------------------
开始安装Apache   
-----------------------------------------------------------------------------------------------------------------------
1.安装向导界面
2.确认同意软件安装使用许可条例
3.使用须知
4.     Network Domain下填入您的域名
       Server Name下填入您的服务器名称
         Administrator's Email Address下填入系统管理员的联系电子邮件地址
5.Typical为默认安装
    Custom为用户自定义安装(随意选择目录)
6. 开始一路回车法.
7.安装完后在安装目录下有个conf文件夹,打开httpd.conf文件进行配置
·找到 DocumentRoot ,将其设置为你所要存放php, htm等网页文件的文件夹,如 "D:\www "
(默认D:\apache安装目录\htdocs)
·找到 DirectoryIndex ,在index.html后添加index.php, index.htm等,以单个空格将其分开;
·重启Apache,用http://localhosthttp://127.0.0.1http://yourcompanyname测试是否成功。
成功的话屏幕会有个It works!

-----------------------------------------------------------------------------------------------------------------------
安装Php
-----------------------------------------------------------------------------------------------------------------------
解压缩到任何目录 比如D:php5
1.复制php.ni 到 D:\apache安装目录\conf\php.ini
2.修改phpini 文件
     extension_dir= DLL文件目录 "D:php5/extensions"
打开httpd.conf,添加下面内容
       LoadModule php5_module "d:/php/php5apache2_2.dll"
       PHPIniDir D:\apache安装目录\conf\php.ini      
       AddType application/x-httpd-php .php
       找到<Directory />
                         Options FollowSymLinks
                        AllowOverride None
                          Order deny,allow
                           Deny from all                 allow from all
          </Directory>                                  //不该会造成403 Forbidden错误
相关信息:http://hi.baidu.com/%C1%C9%C4%FE%C8%CB%C3%F1%BB%B6%D3%AD%C4%FA/blog/item/7e54f33f35c199eb55e72349.html

-----------------------------------------------------------------------------------------------------------------------
安装Mysql
-----------------------------------------------------------------------------------------------------------------------
一路回车法.或具体参考
http://hi.baidu.com/%C1%C9%C4%FE%C8%CB%C3%F1%BB%B6%D3%AD%C4%FA/blog/item/9237573511c4621690ef3913.html
-----------------------------------------------------------------------------------------------------------------------
安装Phpmyadmin
-----------------------------------------------------------------------------------------------------------------------
下载压缩文件解压到D:www/myadmin
然后找到配置文件 libraries/config.default.php
$cfg['Servers'][$i]['host'] = '127.0.0.1';
$cfg['Servers'][$i]['password'] = '123';
Phpmyadmin 需要修改php.ini
extension=php_mbstring.dll


配置文件现在需要绝密的短语密码(blowfish_secret)。
$cfg['blowfish_secret'] = ' ';    单引号里面随便写个数