zoukankan      html  css  js  c++  java
  • [转】IIS:Do not nest virtual directories

    原文:https://msdn.microsoft.com/en-us/library/ms178685.aspx#Anchor_6

    Configuration settings for virtual directories are independent of physical directory structure, and virtual directories must be organized carefully to avoid configuration problems. For example, you could have an ASP.NET file named MyResource.aspx with the following physical directory structure.

    C:Subdir1         
              Subdir2             
                      MyResource.aspx
    

    In addition, you might have a configuration file that is located in Subdir1, a virtual directory named Vdir1 that is mapped to c:Subdir1, and a virtual directory named Vdir2 that is mapped to c:Subdir1Subdir2. If a client accesses the resource with the physical location of c:Subdir1Subdir2MyResource.aspx using the URL http://localhost/vdir1/subdir2/MyResource.aspx, the resource inherits configuration settings from Vdir1. However, if the client accesses the same resource using the URL http://localhost/vdir2/MyResource.aspx, it does not inherit settings from Vdir1.(直接通过vdir2访问资源时,vdir1下的web.config不会被继承。) Creating virtual directories in this manner can cause unexpected results, or even an application failure. It is recommended that you do not nest virtual directories, or if you do, use only one Web.config file.

  • 相关阅读:
    [BZOJ 2144]跳跳棋
    [NOIp 2015]信息传递
    [JLOI 2014]松鼠的新家
    [Luogu 2062]分队问题
    [Luogu 2090]数字对
    [NOIp 2015]运输计划
    [USACO 03FEB]Farm Tour
    [TJOI 2010]中位数
    IO密集型 计算密集型
    python 编码
  • 原文地址:https://www.cnblogs.com/rader/p/4962277.html
Copyright © 2011-2022 走看看