当前位置:编程学习 > C#/ASP.NET >>

location 的 path 问题

网站根目录下的WEBCONFIG里的LOCATION,如果是在若干层文件夹以后的,要怎样表示.
比如根目录下的文件夹为file1,里面有file2,里面有file3


<location path="???">
    <system.web>
      <authorization>
      <deny users="?"/>
      </authorization>
    </system.web>
  </location> --------------------编程问答-------------------- <location   path= "~/file1/file2/"> 
        <system.web> 
            <authorization> 
            <deny   users= "? "/> 
            </authorization> 
        </system.web> 
    </location>  --------------------编程问答-------------------- 也可以在file1,file2添加config文件 --------------------编程问答--------------------
t0:vicqqq 用path=  "~/file1/file2/ ">  出现以下的错误
Parser Error Message: <location> path attribute must be a relative virtual path.  It cannot end with any of ' ' '.' '/' or '\'.
--------------------编程问答-------------------- 用这样可以:
path="file1/file2"
补充:.NET技术 ,  ASP.NET
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,