关于web.config身份验证的问题(回答贴边就给分)
web.config里的身份验证和授权
我的站点里根目录下的文件.aspx是不需要登陆就可浏览的,
我想使站点里的一个文件夹中的内容需要登陆后才能浏览
这样怎样配置web.config啊
下面是我的web.config文件,在根目录下
<configuration>
<system.web>
<authentication mode="Forms" >
<forms loginUrl="logon.aspx" name=".FormsAuthCookie"/>
</authentication>
<authorization>
<allow users="*"/>
</authorization>
</system.web>
<location path="Customer"> Customer文件夹位于根目录下
<deny users="?"/>
</location>
</configuration>
Login.aspx位于根目录下
当我请求Customer 文件夹中的.aspx时 页面转向login.aspx,登陆之后进入Customer文件中的aspx页
当我通过Customer文件中的aspx页的链接,连到Customer文件中的页时又转道Login.aspx页.还要再登陆一次
怎么回事啊?
多谢各位指点!!!