Client-side access to current domain name

rwmarejka
Kilo Contributor

On the server-side the current domain can be accessed using gs.getUser().getDomainDisplayValue() and gs.getUser().getDomainID().

The clients-side g_user (http://wiki.servicenow.com/index.php?title=GlideUser_(g_user)) documents 4 properties and 6 methods, none of which directly facilitate domain access.

Is there a client-side equivalent?

2 REPLIES 2

CapaJC
ServiceNow Employee
ServiceNow Employee

There is not currently a client-side equivalent. If you need either on a form, you can populate a g_scratchpad variable with what you need using a "display" Business Rule.
http://wiki.servicenow.com/index.php?title=Business_Rules#Display_Business_Rules


I am trying to figure out a g_scratchpad variable type scenario for Catalog items (cannot access g_scratch pad). The only answer I have found is using glide Ajax but no specific instructions seem to be available. Any idea how this can be done for catalog items?