Jump to content
Welcome to our new Citrix community!

storefront 3.x - How to get the logged in user id and domain name.


Lokesh S

Recommended Posts

After user logged into the SF webpage it displays the user full name only. Is there any way to get the username and domain name by which the user logged in. I need this data to customise the content displayed for the user based on the domain and id.

 

Link to comment
Share on other sites

  • 1 year later...
  • 5 months later...
  • 2 years later...

well in the \storeweb\custom\script.js file add the following .

 

CTXS.Extensions.afterDisplayHomeScreen = function (callback) {
	setTimeout( function() {
		$("p.user-display-name").text(($("p.user-display-name").text()).replace("domain\\",""))
	},500);
	callback();
}; 

in the style.css within same folder add the following for font size to accommodate long usernames

 

.user-display-name{
	font-size:12px!important;
}

For only to fetch Username 

 

$("p.user-display-name").text();

 

Link to comment
Share on other sites

  • 3 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...