How to customize menu of a website ???
Hi all !.I'm using .NET 2003
In my site ,I want to customize the menu of the site.For instance,when user logged in then menu Login become Log out .
Can any one give me an advice .
Thanks you very much !
They have 3 video tutorials on login and profile management
while those video clips are great resources for learning how to implement .net programming into once application, if you pay attention to nobitavn94's original post, he is using vs.net2003 which is .net 1.x, not 2.0.
login and profile management from those video clips are for 2.0, which needs to be using vs.net 2005 or vwd.
unless nobitavn94 is ready to move to 2.0, those video clips would be waste his(her) time without resolution.
Unless you purchase a third party component; there is no built-in role management support in .net 1.x.
You'll have to implement the whole thing by yourself (which is really not that bad). There are many ways to handle it, but off the top of my head, this is what I would do:
1) make 2 menus using User Control ascx, 1 with "sign in " link and the other one with "log out" link.
2) in your aspx page(s), put a placeholder control as where you think the menu should be located.
3) store a username/password somewhere in your sessions, and default name/password to something bogus.
4) I assume you use FormAuthentication to manage logged in user, so you do the following under your page_load method:
//grab username/password from sessions...
if (FormsAuthentication.Authenticate(UserName, UserPassword))
con = LoadControl ("login.ascx");
con = LoadControl ("logout.ascx");
Last edited by sirpelidor; 11-13-2006 at 01:09 PM.
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)