Categories


Tags


windows+iis脚本映射方式实现伪静态(包括asp.net)

一 . Windows2008、2012或更高系统

只需要在设置脚本影射的目录下创建web.config文件,其内容为

<?xml version="1.0" encoding="UTF-8"?>

<configuration>

<system.webServer>

<handlers>

<add name="ttt-map" path="*.ttt" verb="*" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll" resourceType="File" preCondition="classicMode,runtimeVersionv4.0,bitness32" />

</handlers>

</system.webServer>

</configuration>

注意: name="ttt-map" 所在行代码设置是将ttt后缀的文件映射到aspnet4.0或aspnet4.5,path="*.ttt"部分请自行按需求修改.

二 . 其他示例:

1.将html后缀的文件映射到aspnet2.0或aspnet3.5

<add name="html" path="*.html" verb="*" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll" resourceType="File" preCondition="classicMode,runtimeVersionv2.0,bitness32" />

2.将html后缀的文件映射到asp

<add name="html" path="*.html" verb="*" modules="IsapiModule" scriptProcessor="%windir%\system32\inetsrv\asp.dll" resourceType="File" preCondition="bitness32" />

3.将html后缀的文件映射到php5.2isapi模式,5.2cgi模式,5.3,5.4版本(我司虚拟主机对应路径)

<add name="html" path="*.html" verb="*" modules="IsapiModule" scriptProcessor="C:\php_52\php5isapi.dll" resourceType="File" preCondition="bitness32" />

<add name="html" path="*.html" verb="*" modules="CgiModule" scriptProcessor="C:\php_52\php.exe" resourceType="File" preCondition="bitness32" />

<add name="html" path="*.html" verb="*" modules="FastCgiModule" scriptProcessor="C:\php_53\php.exe" resourceType="File" preCondition="bitness32" />

<add name="html" path="*.html" verb="*" modules="FastCgiModule" scriptProcessor="C:\php_54\php-cgi.exe" resourceType="File" preCondition="bitness32" />

注意:如果自身已经是aspnet程序,可直接在system.webServer的handlers节中添加相应映射代码,另外还需将程序池切换到经典模式,并开启32兼容脚本映射设置才会生效

如果需要设置全局的通配符映射,直接在控制面板-伪静态设置-.NET通配符映射启用即可

来源:西部数码


Public @ 2014-02-28 16:11:04

centos 6.4安装Lumanager后出现大量postdrop进程的解决办法

问题描述: 在CentOS 6.4系统上安装了Lumanager后,出现大量postdrop进程,导致系统负载高、系统运行缓慢等问题。 解决方法: 1. 修改Lumanager的配置文件 在Lumanager安装目录下的/etc/lumanager.conf文件中,找到以下两行并注释掉: post_service = postdrop sendmail_path = /usr/sbin/

Public @ 2023-03-26 04:50:24

Windows Server 2012 IIS安装教程

这篇文章主要介绍了Windws Server 2012的网站环境配置之安装IIS方法,需要的朋友可以参考下。Windows Server 2012 R2是目前主流的服务器系统之一,其使用简单,性能卓越,已经有越来越多的公司使用其作为业务服务的载体。互联网信息服务IIS(Internet Information Services),是由微软公司提供的基于运行Microsoft Windows的互联网

Public @ 2014-03-23 15:47:25

IIS 6.0 伪静态的配置方法

1. 打开IIS 6.0控制台,选中需要配置伪静态的网站或虚拟目录,右键选择“属性”; 2. 在“属性”窗口中选择“主页”选项卡,点击“文件”按钮; 3. 在“文件”窗口中点击“添加”按钮,添加需要伪静态的文件名和规则; 4. 选择“限制”按钮,设置规则的限制条件,如访问IP、HTTP方法等; 5. 确认设置无误后,点击“确定”保存配置。 注意事项:伪静态操作需要确保服务器已经安装了ISAPI筛

Public @ 2023-04-05 16:00:11

更多您感兴趣的搜索

0.451601s