iis7.5是安装在win7、win8里的web服务器,win2003、win2000的web服务器使用的是iis6.0,由于win7、win8系统相比win2003、win2000有了改新革面的不同,因此对于iis7.5的配置也必需捣鼓一翻才能熟悉。不过这些都是操作性的东西,就如当初第一次接触iis6.0那样,操作过几遍就慢慢熟悉了。
当下我需要web服务器运行php程序,因此要配置一下php环境。一开始以为比较容易,因为在iis6.0里配置了无数次了,星外PHP全自动安装30秒轻松搞定,但是当打开iis7.5后,才发现原先iis6.0的熟悉的东西大部分在iis7.5里找不到了,不得不摸索一翻。本文结合自己的实际经验,介绍一下如何在iis7.5安装配置php。
1.准备文件
首先确保你已经下载并且解压了php程序文件,如果还没有,先下载一个。php程序文件是不需要安装的,把下载的压缩包解压到任何一个文件夹里即可。本案例里使用的是PHP 5.2.13。
官网下载Php执行文件:http://windows.php.net/download/
2.IIS配置2.1 添加ISAPI筛选器
进入“控制面板”-“程序”-“打开或关闭Windows功能”,展开“Internet信息服务”,然后勾选“ISAPI筛选器”,最后点击“确定”按钮,如下图所示:
图1:打开ISAPI筛选器
2.2 设置ISAPI2.2.1 打开IIS管理器
进入IIS管理器(方法:右键点击“计算机”,再点击“管理”,在弹出界面里展开“服务和应用程序”的项目,然后双击“Internet 信息服务(IIS)管理器”),进入IIS管理界面,如下图。
图2:打开IIS管理器
2.2.2 添加PHP的ISAPI路径
在上图2中,双击“ISAPI和CGI限制”的图标,之后进入设置界面,如下图。
图3:添加PHP ISAPI
如上图3所示,点击“添加”,在弹出窗口里输入php的ISAPI路径,也即是php解压包的php5isapi.dll的文件路径,描述文字随意填写,如“php”,勾选“允许执行扩展路径”,然后点击“确定”。
2.2.3 添加PHP的处理程序映射
点击一下计算机名称(更正:应该是点击“网站”下面的需要设置的网站名称,而不是最顶部的计算机名称,这个设置是针对某一个网站的),会看到右侧的“IIS”下面有个“处理程序映射”的图标,如下图。
图4:IIS处理程序映射
双击“处理程序映射”的图标,就进入设置界面,如下图:
图5:添加PHP处理程序映射
在设置界面里点击“添加脚本映射...”,然后在弹出窗口里填写相应的内容,请求路径是“*.php”,可执行文件是php解压包的php5isapi.dll的文件路径,跟图3填写的路径一样。名称随意,可填“php”,请求限制不用设置,点击“确定”添加完毕。
2.2.4 测试Php
用记事本输入以下几行代码:
<?php phpinfo(); ?>
保存为:info.php,放到网站目录下,然后启动浏览器,访问 http://localhost/info.php,如果看到如下画面就证明安装成功了!
图6:php运行成功界面
以上所述就是本文的全部内容了,希望大家能够喜欢。

What’s still popular is the ease of use, flexibility and a strong ecosystem. 1) Ease of use and simple syntax make it the first choice for beginners. 2) Closely integrated with web development, excellent interaction with HTTP requests and database. 3) The huge ecosystem provides a wealth of tools and libraries. 4) Active community and open source nature adapts them to new needs and technology trends.

PHP and Python are both high-level programming languages that are widely used in web development, data processing and automation tasks. 1.PHP is often used to build dynamic websites and content management systems, while Python is often used to build web frameworks and data science. 2.PHP uses echo to output content, Python uses print. 3. Both support object-oriented programming, but the syntax and keywords are different. 4. PHP supports weak type conversion, while Python is more stringent. 5. PHP performance optimization includes using OPcache and asynchronous programming, while Python uses cProfile and asynchronous programming.

PHP is mainly procedural programming, but also supports object-oriented programming (OOP); Python supports a variety of paradigms, including OOP, functional and procedural programming. PHP is suitable for web development, and Python is suitable for a variety of applications such as data analysis and machine learning.

PHP originated in 1994 and was developed by RasmusLerdorf. It was originally used to track website visitors and gradually evolved into a server-side scripting language and was widely used in web development. Python was developed by Guidovan Rossum in the late 1980s and was first released in 1991. It emphasizes code readability and simplicity, and is suitable for scientific computing, data analysis and other fields.

PHP is suitable for web development and rapid prototyping, and Python is suitable for data science and machine learning. 1.PHP is used for dynamic web development, with simple syntax and suitable for rapid development. 2. Python has concise syntax, is suitable for multiple fields, and has a strong library ecosystem.

PHP remains important in the modernization process because it supports a large number of websites and applications and adapts to development needs through frameworks. 1.PHP7 improves performance and introduces new features. 2. Modern frameworks such as Laravel, Symfony and CodeIgniter simplify development and improve code quality. 3. Performance optimization and best practices further improve application efficiency.

PHPhassignificantlyimpactedwebdevelopmentandextendsbeyondit.1)ItpowersmajorplatformslikeWordPressandexcelsindatabaseinteractions.2)PHP'sadaptabilityallowsittoscaleforlargeapplicationsusingframeworkslikeLaravel.3)Beyondweb,PHPisusedincommand-linescrip

PHP type prompts to improve code quality and readability. 1) Scalar type tips: Since PHP7.0, basic data types are allowed to be specified in function parameters, such as int, float, etc. 2) Return type prompt: Ensure the consistency of the function return value type. 3) Union type prompt: Since PHP8.0, multiple types are allowed to be specified in function parameters or return values. 4) Nullable type prompt: Allows to include null values and handle functions that may return null values.


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

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

MantisBT
Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

Dreamweaver Mac version
Visual web development tools

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

PhpStorm Mac version
The latest (2018.2.1) professional PHP integrated development tool

WebStorm Mac version
Useful JavaScript development tools