search

在IIS6上安装PHP5(以PHP5.2.0为例)
1、首先在php.net上下载windows用的zip包。然后解压,如解压在“C:\php5”

2、把根目录下的php5ts.dll复制到系统windows目录下;把php.ini-dist文件改名为php.ini后复制到系统windows目录下。

3、用文本编辑器打开php.ini文件,查找“register_globals”,把后面的Off改为On。该项设置是关于自定义全局变量。

4、查找“extension_dir”,把后面的值改为php解压文件夹的ext子目录下,如“C:\php5\ext”

5、查找“extension”,把需要用到的扩展模块前的;号去掉。如需要用mysql的就是php_mysql.dll,如需要用mysqli的话,就需要自己加一句extension=php_mysqli.dll。有些扩展库可能需要额外的 DLL 才能工作,具体请查看这里,如果列表里的注解中有说明,则需要在解压根目录或者ext子目录找到该文件,然后复制到系统windows目录中。
如php_mysql.dll和php_mysqli.dll就需要把根目录下的libmysql.dll复制到系统windows目录中

6、打开IIS,找到需要使用php的站点,点右键-属性,找到“主目录”选项卡,点击“配置”按钮,在“映射”选项卡中,点“添加”按钮,通过“浏览”,找到php解压目录下的php5isapi.dll文件,确定,“扩展名”填“.php”,其他选项默认即可。

7、找到IIS的web服务扩展,点击“添加一个新的web服务扩展”,扩展名可以为“php”,添加文件同样为php5isapi.dll,并把“设置扩展状态为允许”勾选。

8、在开始-运行里输入iisreset,确定,重启IIS。至此,在IIS6上安装PHP5已经完成。

常见问题:
1、如出现一些“failed to open stream”等提示,一般是因为权限问题,我的解决方法是给everyone对php的解压目录的读取和运行权限,给iis两个用户对网站的web目录读取和运行权限。相关参考文章:[小勤]WIN主机配置PHP的若干问题解决方案总结

PS:关于php.ini里的选项设置,可以查看这里。

在Windows上安装MySQL5(以5.0.24a为例)
在mysql.com上下载windows的安装文件,然后运行,根据提示一步步next,基本上不需要做任何调整。安装完成后会自动打开配置程序,根据需要做一些调整。至最后一步,配置程序可能会提示无法连接数据服务器,这时候,需要点击重试按钮,否则可能会发生程序无法连接服务器的情况。

如果出现如上所述情况,需通过mysql自身的卸载程序卸载mysql,并把安装目录和数据目录清空,重启,然后再安装。否则将会重复之前的问题。我第一次就是在这里卡了好久一段时间。

在IIS6上安装Perl5(以5.8.8.819为例)
1、在ActiveState上下载ActivePerl,运行,根据提示完成安装。

2、打开IIS,找到需要使用perl的站点,点右键-属性,找到“主目录”选项卡,点击“配置”按钮,在“映射”选项卡中,点“添加”按钮,通过“浏览”,找到perl安装目录的bin子目录,把查找文件类型设为CGI(*.exe文件),选择perl.exe文件,确定,“扩展名”填“.pl”,其他选项默认即可。

3、找到IIS的web服务扩展,把“Perl CGI Extension”设为允许状态。

4、对perl的安装目录,给予iis的两个帐户以读取和运行、修改、写入的权限。


在IIS6上安装DevMS的IIS-Tools(以1.1.0.0为例)
1、在DevMS.Com上下载压缩包,解压。

2、打开IIS,找到需要使用IIS-Tools的站点,点右键-属性,找到“ISAPI筛选器”选项卡,点击“添加”按钮,筛选器名称可以为“devms”,浏览文件,找到解压包里的Devms.Com.IISTools.dll文件。确定添加。

3、找到IIS的web服务扩展,点击“添加一个新的web服务扩展”,扩展名可以为“devms”,添加文件同样为Devms.Com.IISTools.dll,并把“设置扩展状态为允许”勾选。

4、对网站的web目录,给予SERVICE帐户的完全权限。

5、重启IIS即可。

PTW:
DevMs的IIS-Tools特性:
1、URL重定向(URL ReWrite)
完全支持各类型的URL重定向.如常见的无后缀名等
通过正则表达式设定重定向匹配项目.最多可达255个项目
支持对文件的访问请求有条件进行监控,如cookie、引用来源等

2、防盗链
实现了文件非法访问监控(防止盗链).允许使用引用来源和COOKIE验证两种方法

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
11 Best PHP URL Shortener Scripts (Free and Premium)11 Best PHP URL Shortener Scripts (Free and Premium)Mar 03, 2025 am 10:49 AM

Long URLs, often cluttered with keywords and tracking parameters, can deter visitors. A URL shortening script offers a solution, creating concise links ideal for social media and other platforms. These scripts are valuable for individual websites a

Introduction to the Instagram APIIntroduction to the Instagram APIMar 02, 2025 am 09:32 AM

Following its high-profile acquisition by Facebook in 2012, Instagram adopted two sets of APIs for third-party use. These are the Instagram Graph API and the Instagram Basic Display API.As a developer building an app that requires information from a

Working with Flash Session Data in LaravelWorking with Flash Session Data in LaravelMar 12, 2025 pm 05:08 PM

Laravel simplifies handling temporary session data using its intuitive flash methods. This is perfect for displaying brief messages, alerts, or notifications within your application. Data persists only for the subsequent request by default: $request-

Build a React App With a Laravel Back End: Part 2, ReactBuild a React App With a Laravel Back End: Part 2, ReactMar 04, 2025 am 09:33 AM

This is the second and final part of the series on building a React application with a Laravel back-end. In the first part of the series, we created a RESTful API using Laravel for a basic product-listing application. In this tutorial, we will be dev

Simplified HTTP Response Mocking in Laravel TestsSimplified HTTP Response Mocking in Laravel TestsMar 12, 2025 pm 05:09 PM

Laravel provides concise HTTP response simulation syntax, simplifying HTTP interaction testing. This approach significantly reduces code redundancy while making your test simulation more intuitive. The basic implementation provides a variety of response type shortcuts: use Illuminate\Support\Facades\Http; Http::fake([ 'google.com' => 'Hello World', 'github.com' => ['foo' => 'bar'], 'forge.laravel.com' =>

cURL in PHP: How to Use the PHP cURL Extension in REST APIscURL in PHP: How to Use the PHP cURL Extension in REST APIsMar 14, 2025 am 11:42 AM

The PHP Client URL (cURL) extension is a powerful tool for developers, enabling seamless interaction with remote servers and REST APIs. By leveraging libcurl, a well-respected multi-protocol file transfer library, PHP cURL facilitates efficient execution of various network protocols, including HTTP, HTTPS, and FTP. This extension offers granular control over HTTP requests, supports multiple concurrent operations, and provides built-in security features.

12 Best PHP Chat Scripts on CodeCanyon12 Best PHP Chat Scripts on CodeCanyonMar 13, 2025 pm 12:08 PM

Do you want to provide real-time, instant solutions to your customers' most pressing problems? Live chat lets you have real-time conversations with customers and resolve their problems instantly. It allows you to provide faster service to your custom

Announcement of 2025 PHP Situation SurveyAnnouncement of 2025 PHP Situation SurveyMar 03, 2025 pm 04:20 PM

The 2025 PHP Landscape Survey investigates current PHP development trends. It explores framework usage, deployment methods, and challenges, aiming to provide insights for developers and businesses. The survey anticipates growth in modern PHP versio

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
Repo: How To Revive Teammates
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island Adventure: How To Get Giant Seeds
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌

Hot Tools

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function

Dreamweaver Mac version

Dreamweaver Mac version

Visual web development tools

ZendStudio 13.5.1 Mac

ZendStudio 13.5.1 Mac

Powerful PHP integrated development environment

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

mPDF

mPDF

mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),