具有特权的ASP.Net登录页面 [英] ASP.Net login page with previledge

查看:98
本文介绍了具有特权的ASP.Net登录页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好..
我需要创建一个登录页面,在登录页面中,它将在登录后检查用户权限,如果用户是普通用户,它将显示带有5个菜单项的菜单条,或者如果用户是管理员,则将显示带有6个菜单项的菜单它.

请帮我...

hello every one..
i need to create a login page in which after login it will check for user previledge and if the user is normal user it will show a menu strip with 5 menu item or if the user is admin it will show the menu with 6 menu items on it.

please help me with this ...
thanx in advance.

推荐答案

^ ]

http://forums.asp.net/t/1644440.aspx [
Binding Sitemaps with Menu Control Based on User Privilege at Runtime[^]

http://forums.asp.net/t/1644440.aspx[^]




您可以按以下方式实现此Senario.

1.为普通用户和管理员用户创建2个不同的控件(一个带有5个菜单项,另一个带有6个菜单项).在检查用户的访问级别之后,动态添加控件.

2.将菜单项添加到母版页中,然后根据登录用户以html显示和隐藏其他菜单项.您可以将用户类型保存到会话对象中,并且将在每次请求时进行验证.

希望对您有帮助.
Hi,

You can implement this senario as below.

1. Create 2 different control(one with 5 menu item and the other with 6menu item) for normal and admin user. Add control dynamically after checking the access level of the user.

2. Add menu item into master page and Show and hide extra menu item in html according to the logon user. You can save user type into session object and will be validated on every request.

Hope this will help you.


这篇关于具有特权的ASP.Net登录页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆