具体你可以看这儿
http://www.csdn.net/expert/topic/1008/1008822.xml?temp=.2041132

解决方案 »

  1.   

    这是win98的(转)
    在WINDOWS98环境下安装php-4.2.1-Win32+apache_2.0.39-win32-x86-no_ssl+mysql-max-4.0.1-alpha-win 1、首先安装MYSQL,按照默认的方式安装到c:\mysql 下 
    2、解开PHP压缩文件,放置在C:\php-4.2.1目录下 
    3、更改extension_dir=\.为 extension_dir=c:\php-4.2.1\extensions\ 
    4、安装APACHE,到目录C:\apache\下面 
    5、更改c:\apache\apache2\conf\httpd.conf的设置 找到这一行:“DirectoryIndex index.html index.html.var ” 
    更改为:“DirectoryIndex index.html index.html.var index.php index.php4 index.php3” 找到这一行:“DocumentRoot "C:/apache/Apache2/htdocs"” 
    更改为:DocumentRoot "e:\myphp"(注:此目录是服务器默认的根目录,可根据自己的需要选择) 
    这一行:“<Directory "C:/apache/Apache2/htdocs">”也要依据上面做相应的更改 
    我改成:<Directory "e:\myphp"> 最后在文件尾加上:ScriptAlias /php4/ "C:/php-4.2.1/" (注:只需把引号中的内容做相应的更改即可) 
    AddType application/x-httpd-php4 .php 
    AddType application/x-httpd-php4 .php3 
    AddType application/x-httpd-php4 .php4 
    Action application/x-httpd-php4 "/php4/php.exe" 另:以上配置完后APACHE基本上就能正确的解析PHP了,但其中还有一点小的设置需更改 
    1、在C:\apache\apache2\conf\httpd.conf中找到“AddDefaultCharset ISO-8859-1”将其改为:“AddDefaultCharset GB2312”,这样你的APACHE才能正确的显示中文