- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā03-20-2024 07:55 PM
We have created widget. In html . Written url and their href link. And then moved to other instances. But when clone and upgrades happens. It's url automatically gets changes . Pointing towards other instance. How to make it dynamically via system properties
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā03-20-2024 09:21 PM - edited ā03-20-2024 09:21 PM
Please dont create this system properties in your instance. these system properties are managed by servicenow directly.
you can use background script to get output of that system properties in different instances
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā03-20-2024 08:40 PM - edited ā03-20-2024 08:42 PM
Hi @Aditya1204,
You can use gs.getProperty("glide.servlet.uri") to get the URL of instance, like https://dev.service-now.com/ in your server side script and store it in the data variable like,
data.inst_url = gs.getProperty("glide.servlet.uri") + "esc?id=services";
Then in your HTML you can use this like,
<a href="{{c.data.inst_url}}" style="margin: 10px 0;white-space: pre;">Get in touch with your Manager</a>
This will take care of instance name dynamically.
Thanks
SP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā03-20-2024 09:08 PM
Will check and let you know.
Thanks for quick help
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā03-20-2024 09:21 PM - edited ā03-20-2024 09:21 PM
Please dont create this system properties in your instance. these system properties are managed by servicenow directly.
you can use background script to get output of that system properties in different instances
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā03-20-2024 10:17 PM
HI SP22..
I have to display report url link after https://dev.service-now.com/, what should I add in place of
"esc?id=services";