# 正常情况下的输出如下 # Installing the 'Apache2.4' service The 'Apache2.4' service is successfully installed. Testing httpd.conf.... Errors reported here must be corrected before the service can be started. AH00558: httpd.exe: Could not reliably determine the server's fully qualified domain name, ...
Are you installing a system-wide PEAR or a local copy? (system|local) [system] :
Below is a suggested file layout for your new PEAR installation. To change individual locations, type the number in front of the directory. Type 'all' to change all of them or simply press Enter to accept these locations. 1. Installation base ($prefix) : C:\php 2. Temporary directory for processing : C:\php\tmp 3. Temporary directory for downloads : C:\php\tmp 4. Binaries directory : C:\php 5. PHP code directory ($php_dir) : C:\php\pear 6. Documentation directory : C:\php\docs 7. Data directory : C:\php\data 8. User-modifiable configuration files directory : C:\php\cfg 9. Public Web Files directory : C:\php\www 10. System manual pages directory : C:\php\man 11. Tests directory : C:\php\tests 12. Name of configuration file : C:\WINDOWS\pear.ini 13. Path to CLI php.exe : C:\php
1-13, 'all' or Enter to continue: 12 (Use $prefix as a shortcut for 'C:\php', etc.) Name of configuration file [C:\WINDOWS\pear.ini] : C:\php\pear.ini
Below is a suggested file layout for your new PEAR installation. To change individual locations, type the number in front of the directory. Type 'all' to change all of them or simply press Enter to accept these locations.
1. Installation base ($prefix) : C:\php 2. Temporary directory for processing : C:\php\tmp 3. Temporary directory for downloads : C:\php\tmp 4. Binaries directory : C:\php 5. PHP code directory ($php_dir) : C:\php\pear 6. Documentation directory : C:\php\docs 7. Data directory : C:\php\data 8. User-modifiable configuration files directory : C:\php\cfg 9. Public Web Files directory : C:\php\www 10. System manual pages directory : C:\php\man 11. Tests directory : C:\php\tests 12. Name of configuration file : C:\php\pear.ini 13. Path to CLI php.exe : C:\php
1-13, 'all' or Enter to continue: Beginning install... Configuration written to C:\php\pear.ini... Initialized registry... Preparing to install... ...
# 以下命令用于检查 pear 安装结果 # C:\> where pear C:\php\pear.bat
C:\> pear Commands: build Build an Extension From C Source bundle Unpacks a Pecl Package channel-add Add a Channel ...
C:\> pear version PEAR Version: 1.10.1 PHP Version: 7.0.6 Zend Engine Version: 3.0.0 Running on: Windows NT HUANG 10.0 build 10586 (Windows 10) i586
安装 MySQL 可以使用其官方网站上提供的安装包,几乎不会有任何问题,所以不介绍具体过程。这里只给出测试 MySQL 的 PHP 脚本。安装完成后,启动 MySQL 数据库。在C:/Apache24/htdocs目录中创建文件mysql_test.php,输入以下内容,并在浏览器中访问该文件,查看测试结果。