zoukankan
html css js c++ java
表单身份验证(受保护的目录)
根目录下的 web.config
<
authentication
mode
="Forms"
>
<
forms
name
=".COOKIEDEMO"
loginUrl
="bb.aspx"
protection
="All"
timeout
="60"
path
="/"
>
</
forms
>
</
authentication
>
根目录下的.
bb.aspx
if
(
this
.TextBox1 .Text
==
"
abc
"
&&
this
.TextBox2 .Text
==
"
abc
"
)
{
System.Web.Security .FormsAuthentication .RedirectFromLoginPage(
this
.TextBox1 .Text,
false
);
}
else
{
}
根目录下新建一个受保护的目录...
这个目录下的 web.config
<
configuration
>
<
system
.web
>
<
authorization
>
<
deny
users
="?"
/>
</
authorization
>
</
system.web
>
</
configuration
>
demo
https://files.cnblogs.com/gwazy/WebApplication7.rar
查看全文
相关阅读:
window.location无法跳转页面的问题
html doctype作用
ThinkPhp学习09
ThinkPhp学习08
ThinkPhp学习07
ThinkPhp学习06
ThinkPhp学习05
Thinkphp学习04
ThinkPhp学习03
ThinkPhp学习02
原文地址:https://www.cnblogs.com/gwazy/p/112643.html
最新文章
CSS3 经典教程系列:CSS3 线性渐变(linear-gradient)
nodejs端口被占用。
mark
如何解决跨域无法正常请求问题
如何解决代码嵌套太深问题
编写一个方法,输入DOM节点,返回包含所有父节点的一个数组
css3库
前端工程师面试问题列表
数组去重代码怎么写?
css相关问题
热门文章
关于Position的几个值的理解
Html关于行内元素和块元素Mark
sql之left join、right join、inner join的区别
一道JS的简单算法题
Java WebService Demo,基于XFire
逆波兰式计算字符串公式
前端编程,语义化
罗列各种排序Mark
Array.prototype.slice.call(arguments)
regexp模式匹配+location页面跳转+cookie/localstorage本地存储
Copyright © 2011-2022 走看看