obtain url on server side ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-11-2013 11:51 PM
Hello,
Is there a way you can obtain the current url on server side ? (in a script include file)
Something that would retrieve something like "demo006.service-now.com/incident/weirdurl.do?param1=1".
I can't seem to find any solution to this. Any suggestion is welcomed.
Thx in advance for your help.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-12-2013 03:29 AM
I think you are looking for this :
gs.getSession().getStack().get(0);

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-30-2016 05:23 PM
getStack() does not contain the URL from the current request. The top URL in the stack is the previous request. You can see this by careful testing without wrapper pages or by comparing the getStack values to the current URLs reported by gs.action.getGlideURI().

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-08-2018 11:12 PM
Hi,
I used the method that you have mentioned but it gives error
Error Message
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-17-2018 03:17 AM
I think there is a change in methods.
Please now use gs.getSession().getUrlOnStack(); instead(Kingston).