荔园在线

荔园之美,在春之萌芽,在夏之绽放,在秋之收获,在冬之沉淀

[回到开始] [上一篇][下一篇]


发信人: Mic (酷鱼), 信区: DotNET
标  题: How to禁止或允许用户访问某个页面
发信站: 荔园晨风BBS站 (Tue Oct  1 09:05:25 2002), 站内信件

http://sunrise.szu.edu.cn
mic.1/Oct/2002

在web.config里加入节点

<configuration>
  <security>
    <authentication>
      <deny users="?"/>
    </authentication>
  </security>
</configuration>

这样就把anonymous(未login的用户)禁止访问权。
如果我们想赋予匿名用户某个页面的访问权,如首页,可以在location节点加入:

<configuration>
  <location path="Default.aspx">
    <security>
      <authentication>
        <allow users="*" />
      </authentication>
    </security>
  </location>
</configuration>

--
你“唰”的一声抽出一个饭盒握在手中.
>kill da chu
你对大厨喝道:“臭贼!今天不是你死就是我活!放聪明点给我四两!”
看起来大厨似乎想杀死你!
你往南落荒而逃了。
仓皇之间,你丢下一张金龙卡。

※ 来源:·荔园晨风BBS站 bbs.szu.edu.cn·[FROM: 192.168.52.230]


[回到开始] [上一篇][下一篇]

荔园在线首页 友情链接:深圳大学 深大招生 荔园晨风BBS S-Term软件 网络书店