zoukankan      html  css  js  c++  java
  • IIS7.5 伪静态 web.config 配置方法

      iis 7.5

         1)首先新建一个应用程序池,名称任意,比如:nettest,托管管道模式先暂时设置为集成模式,等下面的一系列设置完成之后再设置成经典模式;
         2)部署好站点,并将此站点的应用程序池设置为nettest;
         3)选中站点,切换到功能试图,找到 "服务器组件"-> "处理程序映射",双击之后,在打开窗口右侧的操作栏目下做如下设置:
         4)"添加脚本映射":请求路径 .html ,可执行文件选择 C:WindowsMicrosoft.NETFrameworkv2.0.50727aspnet_isapi.dll ,如果是4.0,则为C:WindowsMicrosoft.NETFrameworkv4.0.30319 aspnet_isapi.dll,名称随意;
         5)"添加通配符脚本映射":请求路径 * ,可执行文件为:C:WindowsMicrosoft.NETFrameworkv2.0.50727aspnet_isapi.dll,名称随意;
         6)"添加托管处理程序":请求路径 * ,可执行文件:System.Web.UI.PageHandlerFactory,名称随意;
         7)打开站点切换到功能试图,找到 "服务器组件"->"模块",双击之后,在打开窗口右侧的操作栏目中,点击"添加托管模块",类型URLRewriter.ModuleRewriter,并且把"仅针对向asp.net 应用程序或托管处理程序发出请求调用" 选中;

         8)最后,找到我们第一步建立的应用程序池nettest,将托管管道模式设置为经典模式。

    (如果为.net4.0,有可能要注册.net4.0)

    web.config

    <RewriterConfig>
        <Rules>
          <RewriterRule>
            <LookFor>~/qqqq/ccccc-(d+)-(d+).htm</LookFor>
            <SendTo>~/xxx/xxxx/Default.aspx?aid=$1&amp;bid=$2</SendTo>
          </RewriterRule>
        </Rules>
    </RewriterConfig>

      <system.webServer>
        <validation validateIntegratedModeConfiguration="false"/>
        <handlers>
          <remove name="SimpleHandlerFactory-ISAPI-4.0_64bit"/>
          <add name="SimpleHandlerFactory-ISAPI-4.0_64bit" path="*.htm" verb="GET,HEAD,POST,DEBUG" modules="IsapiModule" scriptProcessor="C:WindowsMicrosoft.NETFramework64v4.0.30319aspnet_isapi.dll" resourceType="Unspecified" requireAccess="Script" preCondition="classicMode,runtimeVersionv4.0,bitness64" responseBufferLimit="0"/>
        </handlers>
        <modules>
          <add name="URLRewriter" type="URLRewriter.ModuleRewriter" preCondition="managedHandler"/>
        </modules>
      </system.webServer>

  • 相关阅读:
    威联通NAS 网站无法登录,可以ssh情况下重启设备方法
    NSNotification的几点说明
    使用UIDatePicker
    scrollView的几个属性contentSize contentOffset contentInset
    创建标题栏,UINavigationBar的使用
    点击tablecell中的一个按钮,确定cell所在的行
    UITextView被键盘遮挡的处理
    UITableViewCell中的UILabel添加手势没有响应的解决方法
    将NSArray反向排序
    图片的左右摆动
  • 原文地址:https://www.cnblogs.com/houkaihua/p/4252405.html
Copyright © 2011-2022 走看看