对《Windows 9x/NT下以Apache的模块方式安装PHP4》的补充
作者: Tony Reeves ()
发表日期: 08/19 14:40
前些日子,是我写了这篇文章!
本来我想为刚刚接触PHP且又使用WIN9X/NT的朋友们提供一些帮助,
为他们早日建立一个小型的调试环境而尽一点自己的微薄之力。
却不想,自己水平太次,文章写的不够全面,而使很多朋友陷入
麻烦之中。
很多人都问我为什么会出现这样的错误?
Syntax error on line 4 of C:/apache/conf/mod_php4.conf:
Cannot load C:/apache/modules/mod_php4 into server:
这里主要有下面几个原因
~~~~~~~~~~~~~~~~~~~~~~
1. mod_php4-4.0.1-pl2.zip中附带的readme.txt文件讲的很清楚
第一条,把你的PHP4目录路径加入到你的PATH中。是不是一定要
加上呢?如果你把php4ts.dll这个文件拷贝到了
c:\windows\system目录下面,那么这一步,就可以省略。否则就
会出现上面提出的错误。
很多朋友既没有把路径加到PATH中,也没有拷贝php4ts.dll这个
文件到%SYSTEM%目录下面。所以就出现了上面的错误。
也许有人会问,把路径加到PATH中?怎么加呢?我在phpinfo()
也就是PHP4的配置文件中看到了PATH 的值,只有c:\windows;
c:\windows\system;c:\mysql\bin\;c:\apache
httpd.conf中没有关于这个PATH的设定选项啊!
这里很简单你只要在autoexec.bat中加上一句
PATH=%PATH%;c:\php4;c:\mysql\bin\;c:\apache;
就可以搞定了。重新启动计算机,打开php4配置文件看看!是不是
到里面了?
因为我考虑到在CGI模式安装PHP4时,大家一定都已经把php4ts.dll
拷贝到%system%下面了,所以没有提到,给大家造成不便,还请见量!
2. 就是mod_php4.dll这个文件,我不知道您的更新观念有多么强,
总之我用的是最新的版本......
这里我要提醒您的是,mod_php4.dll这个文件的版本,如果和你的PHP4
不一样,那么也会出现上面的错误.你把不同版本的mod_php4.dll文件拷贝
到modules下面等于什么也没干!
3. 你压根就没有拷贝mod_php4.dll到modules目录下面,虽然这看起来有些
愚蠢,但是请不要过于自信,你脑袋再聪明也有昏头的时候.还是到modules
下面看看吧!安心一点!!
这个问题就解答到这里,我相信还有别的原因,如果我找到了,我会告诉大家的.
还有朋友问我为什么PHP4安装为APACHE的模块以后,apache的启动速度反而
变慢了!
这并不和我在文章中说的话冲突,我在文章中的意思是,PHP文件的执行效率,
而不是APACHE的速度.
PHP4安装为APACHE的模块,APACHE启动时,必然要加载mod_php4.dll文件.
启动速度肯定会慢!!
APACHE的启动速度应该还和PHP_*.DLL文件有关,打开PHP.INI,把所有你不
需要的php4_***.dll文件都注释掉!
;extension=php4_*.dll
这样会加快启动速度!
因为它启动时,这些文件也是要加载的.
也有人问我为什么PHP4安装为APACHE的模块以后,和机器里的软件发生冲突,
比如不能进行windows查找操作,不能使用editplus,天哪,罪过!
我实在想不出这是什么原因,您还是先杀杀毒再说吧!
Tony Reeves

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



The key to PHPMyAdmin security defense strategy is: 1. Use the latest version of PHPMyAdmin and regularly update PHP and MySQL; 2. Strictly control access rights, use .htaccess or web server access control; 3. Enable strong password and two-factor authentication; 4. Back up the database regularly; 5. Carefully check the configuration files to avoid exposing sensitive information; 6. Use Web Application Firewall (WAF); 7. Carry out security audits. These measures can effectively reduce the security risks caused by PHPMyAdmin due to improper configuration, over-old version or environmental security risks, and ensure the security of the database.

Apache is the basis of many websites because of its stability, reliability and highly configurable. 1.Apache is developed by the Apache Software Foundation, supports a variety of operating systems and provides static and dynamic content services. 2. Its core functions include handling HTTP requests, virtual hosting and modular design. 3. Configuration examples from basic settings to advanced virtual hosts and URL rewrites. 4. Common errors such as permissions, syntax and module loading problems can be solved through corresponding debugging techniques. 5. Performance optimization includes tuning parameters, using cache and load balancing, and following best practices can improve server efficiency and security.

To uninstall an Oracle database: stop the Oracle service, remove the Oracle instance, delete the Oracle home directory, clear the registry key (Windows only), and delete the environment variables (Windows only). Please back up the data before uninstalling.

This article will explain how to improve website performance by analyzing Apache logs under the Debian system. 1. Log Analysis Basics Apache log records the detailed information of all HTTP requests, including IP address, timestamp, request URL, HTTP method and response code. In Debian systems, these logs are usually located in the /var/log/apache2/access.log and /var/log/apache2/error.log directories. Understanding the log structure is the first step in effective analysis. 2. Log analysis tool You can use a variety of tools to analyze Apache logs: Command line tools: grep, awk, sed and other command line tools.

This article introduces several methods to check the OpenSSL configuration of the Debian system to help you quickly grasp the security status of the system. 1. Confirm the OpenSSL version First, verify whether OpenSSL has been installed and version information. Enter the following command in the terminal: If opensslversion is not installed, the system will prompt an error. 2. View the configuration file. The main configuration file of OpenSSL is usually located in /etc/ssl/openssl.cnf. You can use a text editor (such as nano) to view: sudonano/etc/ssl/openssl.cnf This file contains important configuration information such as key, certificate path, and encryption algorithm. 3. Utilize OPE

The steps to start Apache are as follows: Install Apache (command: sudo apt-get install apache2 or download it from the official website) Start Apache (Linux: sudo systemctl start apache2; Windows: Right-click the "Apache2.4" service and select "Start") Check whether it has been started (Linux: sudo systemctl status apache2; Windows: Check the status of the "Apache2.4" service in the service manager) Enable boot automatically (optional, Linux: sudo systemctl

The hiding place of Oracle database on the C drive: Registry: Use the registry editor to search for "Oracle" to find information including installation path, service name, etc. File system: Oracle files are scattered in multiple locations in the C drive, including home directory, system files, temporary files, etc. Environment variables: The environment variables set by Oracle (such as ORACLE_HOME, ORACLE_SID) point to the installation directory and instance name. Careful action: When uninstalling Oracle, you not only need to delete files, but also clean the registry and services. It is recommended to use the official uninstall tool or seek professional help. Space management: Optimize disk space to avoid installing Oracle on C drive; clean temporary files regularly

Reasons for Apache's popularity include its modular design, virtual hosting capabilities, performance optimization, and security. 1. Modular design allows users to load or unload modules, such as mod_rewrite and mod_ssl, according to their needs. 2. The virtual hosting function supports hosting multiple websites on one server. 3. Performance optimization is achieved by enabling KeepAlive, adjusting MPM and using a cache mechanism. 4. Security is guaranteed by regular updates, restricting access and enabling HTTPS.
