Apache+FastCGI+PHP配置详解(Windows)
来源:互联网 发布:你知我知无损 编辑:程序博客网 时间:2024/05/22 02:09
一、版本简介
其实网上有很多关于这方面的配置,但是我根据一部分的配置不能完成测试(可能因为配置有误),但是还要注意的就是版本问题,先说说几个软件的版本;
1、Apache ver 2.0X
2、mod_fastcgi ver 2.4.2
3、php5
其它的版本要么启动不了apache,要么就是提示FastCGI: server "E:/PHP/Install/PHP5/php-cgi.exe" (pid 1600) terminated with exit with status '0'。大家有兴趣可以去研究一下。
二、安装与配置
1、安装Apache2.0,网上能搜索到,在这里就不列出网址了,
2、从http://www.fastcgi.com/dist/old/mod_fastcgi-2.4.2-AP20.dll 下载mod_fastcgi,放在apache安装目录下的modules目录下
3、下载并安装PHP5,具体的配置还得根据你的程序
4、打开httpd.conf,在文件最末尾添加如下代码:
#加载mod_fastcgi模块
LoadModule fastcgi_module modules/mod_fastcgi-2.4.2-AP20.dll
#设置FastCGI运行路径和进程数量
FastCgiServer "E:/PHP/Install/PHP5/php-cgi.exe" -processes 3
#将php-cgi.exe所在的路径定义别名为fcgi-php5,为什么要定义别名呢?请继续看
ScriptAlias /fcgi-php5/ "E:/PHP/Install/PHP5/"
#将以php后缀的文件定义类型为application/x-httpd-php
AddType application/x-httpd-php .php
#使用php-cgi.exe来执行php文件,这里可以看到使用了别名/fcgi-php5/,为什么不直接使用E:/PHP/Install/PHP5/php-cgi.exe这样的格式呢?因为在这里面是不能写:这样的字符的,所以因此这就是为什么我们要定义别名的原因(具体为什么不能用我就不知道了)
Action application/x-httpd-php "/fcgi-php5/php-cgi.exe"
The END....
- Apache+FastCGI+PHP配置详解(Windows)
- windows下apache+fastCGI+PHP的安装与配置小计
- fastcgi+apache+php的配置
- Apache + MySQL + PHP + FastCGI 配置(上)
- Apache + MySQL + PHP + FastCGI 配置(中)
- Apache + MySQL + PHP + FastCGI 配置(下)
- apache下php配置fastcgi代替mod_php
- apache使用fastcgi配置python和php
- windows+apache+fcgid fastcgi运行配置
- windows php + apache 配置
- windows apache php 配置
- Windows 下 Apache 1.3 以 FastCGI 模式运行 PHP
- windows 下apache 以fastcgi形式运行php
- Windows下Apache以FastCGI模式运行PHP
- Windows下Apache以FastCGI模式运行PHP
- windows 下apache 以fastcgi形式运行php
- windows2003下 apache 以fastcgi模式运行php 详解
- windows Apache配置详解
- linux下安装jdk (1.6.0_22)
- 非常高兴
- 海岸线
- Custom Configuration 的两种方法:1.Configuration Sections
- 对同一个Screen对象两次调用UiApplication的pushScreen会导致运行异常
- Apache+FastCGI+PHP配置详解(Windows)
- 虚拟现实现实版夜遇UFO
- 微软开放Windows Phone 7中文开发中心
- Run-time和compile-time概念(转自百度知道ID:Leo239 的回答)
- IIS 安装,版本必须一样,如果用了错误的I386,就无法启动
- ZOJ 1394 Polar Explorer
- 头痛日记20101027
- 矩阵复习二
- virt-manager的虚拟资源中心