Developer forum

Forum » Development » Dynamicweb.Security or Dynamicweb.Login?

Dynamicweb.Security or Dynamicweb.Login?


Reply
Good Day,

I'm trying to use the tag "Global:Extranet.UserName" but doesn't work.

My code:

Security sec = new Security();
sec.ExtranetLogin(user, database.GetPassword(user));

and

Dynamicweb.Login login = new Dynamicweb.Login(user, database.GetPassword(user));
login.Autologin = true;
login.NormalLogin();

but in both cases the tag doesn't work.


Thanks for your support.

Replies

 
Reply
This code works fine:
            Security sec = new Security();
            sec.ExtranetLogin("username", "password");

And if you put the tag "Global:Extranet.UserName" it will show you the name of the current user.

This function "database.GetPassword()" is not a function of Dynamicweb. Maybe that is why you can not  get it work?

Best regards,
Sergey Ivanov

 
Reply
Don't worry about database.GetPassword I'm using that for get the password account and works fine.

The tag is always empty. For example, using an admin account, the tag is empty but you can open the DynamicWeb admin page without problems.


Thanks and sorry for the troubles.
 
Reply
Ooooops sorry!

The problem is the "Extranet/Intranet" module was not available.

Now is working.

 

You must be logged in to post in the forum