<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: Get values from url in Developer forum</title>
    <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460108#M117034</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;Refer below links, it might help you.&lt;/P&gt;
&lt;P&gt;&lt;A href="http://sncommander.com/how-to-get-parametersvalues-from-a-url-in-servicenow/"&gt;http://sncommander.com/how-to-get-parametersvalues-from-a-url-in-servicenow/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.servicenowguru.com/scripting/client-scripts-scripting/parse-url-parameters-client-script/"&gt;https://www.servicenowguru.com/scripting/client-scripts-scripting/parse-url-parameters-client-script/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;Mark it correct and helpful.&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;Bhagyashri Sorte.&lt;/P&gt;</description>
    <pubDate>Thu, 03 Sep 2020 07:04:16 GMT</pubDate>
    <dc:creator>Bhagyashri Sort</dc:creator>
    <dc:date>2020-09-03T07:04:16Z</dc:date>
    <item>
      <title>Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460107#M117033</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;
&lt;P&gt;Can we get certain values in script include from the url that is generated in lookup.&lt;BR /&gt;For eg: If the url coming on clicking the lookup:&lt;BR /&gt;https://dev87573.service-now.com/sys_user_list.do?sysparm_target=sc_req_item.request.requested_for&amp;amp;sysparm_target_value=&amp;amp;sysparm_reference_value=&amp;amp;sysparm_nameofstack=reflist&amp;amp;sysparm_clear_stack=true&amp;amp;sysparm_element=requested_for&amp;amp;sysparm_reference=sys_user&amp;amp;sysparm_view=sys_ref_list&amp;amp;sysparm_additional_qual=&amp;amp;sysparm_client_record=session&lt;BR /&gt;&lt;BR /&gt;If I want the value of&amp;nbsp;sysparm_target. Can we get it in script include or any BR?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 03 Sep 2020 06:57:35 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460107#M117033</guid>
      <dc:creator>Rj27</dc:creator>
      <dc:date>2020-09-03T06:57:35Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460108#M117034</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;Refer below links, it might help you.&lt;/P&gt;
&lt;P&gt;&lt;A href="http://sncommander.com/how-to-get-parametersvalues-from-a-url-in-servicenow/"&gt;http://sncommander.com/how-to-get-parametersvalues-from-a-url-in-servicenow/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.servicenowguru.com/scripting/client-scripts-scripting/parse-url-parameters-client-script/"&gt;https://www.servicenowguru.com/scripting/client-scripts-scripting/parse-url-parameters-client-script/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;Mark it correct and helpful.&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;Bhagyashri Sorte.&lt;/P&gt;</description>
      <pubDate>Thu, 03 Sep 2020 07:04:16 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460108#M117034</guid>
      <dc:creator>Bhagyashri Sort</dc:creator>
      <dc:date>2020-09-03T07:04:16Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460109#M117035</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;
&lt;P&gt;You need to access the URL in your client script and then pass it to the SI. Here is a link that can help you.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.servicenowguru.com/scripting/client-scripts-scripting/parse-url-parameters-client-script/" target="_blank"&gt;https://www.servicenowguru.com/scripting/client-scripts-scripting/parse-url-parameters-client-script/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Kindly mark the comment as a correct answer and also helpful if this helps.&lt;/P&gt;</description>
      <pubDate>Thu, 03 Sep 2020 07:07:28 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460109#M117035</guid>
      <dc:creator>asifnoor</dc:creator>
      <dc:date>2020-09-03T07:07:28Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460110#M117036</link>
      <description>&lt;P&gt;&lt;SN-MENTION class="sn-mention" table="live_profile" sysid="b6159d41dbd8bbc4a39a0b55ca961977"&gt;@Rj27&lt;/SN-MENTION&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;you can access the URL and get the parameter value in server side using below logic&lt;/P&gt;
&lt;PRE class="language-javascript"&gt;&lt;CODE&gt;var value = gs.action.getGlideURI().getMap().get("sysparm_target");

gs.info(value);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Regards&lt;BR /&gt;Ankur&lt;/P&gt;</description>
      <pubDate>Thu, 03 Sep 2020 07:29:31 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460110#M117036</guid>
      <dc:creator>Ankur Bawiskar</dc:creator>
      <dc:date>2020-09-03T07:29:31Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460111#M117037</link>
      <description>&lt;P&gt;Hi Ankur,&lt;BR /&gt;Thanks for the response!&lt;/P&gt;
&lt;P&gt;i tried giving the above but not getting the expected value.&lt;/P&gt;
&lt;P&gt;I have created a filter(sys_filter) on user table. From this filter i am calling a script include.&lt;/P&gt;
&lt;P&gt;var GetValues = Class.create();&lt;BR /&gt;GetValues.prototype = Object.extendsObject(AbstractAjaxProcessor, {&lt;/P&gt;
&lt;P&gt;getVal: function() {&lt;BR /&gt; var value = gs.action.getGlideURI().getMap().get("sysparm_target");&lt;BR /&gt; gs.log("Calling from filters ");&lt;BR /&gt; gs.log("Calling from filters value" + value);&lt;/P&gt;
&lt;P&gt;}&lt;/P&gt;
&lt;P&gt;I am getting the first log but second is not coming.&lt;/P&gt;</description>
      <pubDate>Thu, 03 Sep 2020 10:01:59 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460111#M117037</guid>
      <dc:creator>Rj27</dc:creator>
      <dc:date>2020-09-03T10:01:59Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460112#M117038</link>
      <description>&lt;P&gt;&lt;SN-MENTION class="sn-mention" table="live_profile" sysid="b6159d41dbd8bbc4a39a0b55ca961977"&gt;@Rj27&lt;/SN-MENTION&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;what you got in logs for the url?&lt;/P&gt;
&lt;P&gt;please print this&lt;/P&gt;
&lt;P&gt;var url = gs.action.getGlideURI().toString();&lt;/P&gt;
&lt;P&gt;gs.info('url' + url);&lt;/P&gt;
&lt;P&gt;&lt;SPAN class="ng-scope"&gt; var value = gs.action.getGlideURI().getMap().get("sysparm_target");&lt;BR /&gt; gs.log("Calling from filters ");&lt;BR /&gt; gs.log("Calling from filters value" + value);&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;Regards&lt;BR /&gt;Ankur&lt;/P&gt;</description>
      <pubDate>Thu, 03 Sep 2020 10:48:38 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460112#M117038</guid>
      <dc:creator>Ankur Bawiskar</dc:creator>
      <dc:date>2020-09-03T10:48:38Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460113#M117039</link>
      <description>&lt;P&gt;If this has answered the question, kindly accept the comment as a correct answer so that the question is moved to solved list.&lt;/P&gt;</description>
      <pubDate>Thu, 03 Sep 2020 10:55:41 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460113#M117039</guid>
      <dc:creator>asifnoor</dc:creator>
      <dc:date>2020-09-03T10:55:41Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460114#M117040</link>
      <description>&lt;P&gt;I am not getting anything in log&lt;/P&gt;</description>
      <pubDate>Thu, 03 Sep 2020 12:07:39 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460114#M117040</guid>
      <dc:creator>Rj27</dc:creator>
      <dc:date>2020-09-03T12:07:39Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460115#M117041</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;You cannot capture the url of the lookup using &amp;nbsp;gs.action.getGlideURI() use client script as i suggested above, read and then pass that value&amp;nbsp;to the SI.&lt;/P&gt;</description>
      <pubDate>Thu, 03 Sep 2020 12:12:07 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460115#M117041</guid>
      <dc:creator>asifnoor</dc:creator>
      <dc:date>2020-09-03T12:12:07Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460116#M117042</link>
      <description>&lt;P&gt;&lt;SN-MENTION class="sn-mention" table="live_profile" sysid="b6159d41dbd8bbc4a39a0b55ca961977"&gt;@Rj27&lt;/SN-MENTION&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So does it mean the function is not getting called?&lt;/P&gt;
&lt;P&gt;Regards&lt;BR /&gt;Ankur&lt;/P&gt;</description>
      <pubDate>Thu, 03 Sep 2020 12:49:45 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460116#M117042</guid>
      <dc:creator>Ankur Bawiskar</dc:creator>
      <dc:date>2020-09-03T12:49:45Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460117#M117043</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this has answered your question, kindly mark the comment as a correct answer so that the question is moved to the solved list.&lt;/P&gt;</description>
      <pubDate>Tue, 08 Sep 2020 06:09:36 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460117#M117043</guid>
      <dc:creator>asifnoor</dc:creator>
      <dc:date>2020-09-08T06:09:36Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460118#M117044</link>
      <description>&lt;P&gt;&lt;SN-MENTION class="sn-mention" table="live_profile" sysid="b6159d41dbd8bbc4a39a0b55ca961977"&gt;@Rj27&lt;/SN-MENTION&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I believe the answer you marked as correct is not as per your question asked.&lt;/P&gt;
&lt;P&gt;As per your question you required value of url parameter in the &lt;STRONG&gt;script include or BR&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;But the answer you marked as correct talks about getting it in client script.&lt;/P&gt;
&lt;P&gt;Please mark appropriate response as correct and helpful so that it would benefit future readers.&lt;/P&gt;
&lt;P&gt;Regards&lt;BR /&gt;Ankur&lt;/P&gt;</description>
      <pubDate>Thu, 10 Sep 2020 16:32:28 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460118#M117044</guid>
      <dc:creator>Ankur Bawiskar</dc:creator>
      <dc:date>2020-09-10T16:32:28Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460119#M117045</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I think the requirement is to read the URL of the popup which you cannot access from SI. hence i have suggested to first read it in client script and then pass those values to BR.&lt;/P&gt;
&lt;P&gt;&lt;SN-MENTION class="sn-mention" table="live_profile" sysid="b6159d41dbd8bbc4a39a0b55ca961977"&gt;@Rj27&lt;/SN-MENTION&gt;&amp;nbsp;kindly confirm how you have achieved the requirement.&lt;/P&gt;</description>
      <pubDate>Thu, 10 Sep 2020 17:06:29 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460119#M117045</guid>
      <dc:creator>asifnoor</dc:creator>
      <dc:date>2020-09-10T17:06:29Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460120#M117046</link>
      <description>&lt;P&gt;Hi Ankur n Asif,&lt;/P&gt;
&lt;P&gt;I took the value from client side and passed it to server side. This worked for me hence marked the answer accordingly.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 11 Sep 2020 05:46:16 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460120#M117046</guid>
      <dc:creator>Rj27</dc:creator>
      <dc:date>2020-09-11T05:46:16Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460121#M117047</link>
      <description>&lt;P&gt;Thanks for the update.&lt;/P&gt;</description>
      <pubDate>Fri, 11 Sep 2020 06:18:33 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460121#M117047</guid>
      <dc:creator>Ankur Bawiskar</dc:creator>
      <dc:date>2020-09-11T06:18:33Z</dc:date>
    </item>
    <item>
      <title>Re: Get values from url</title>
      <link>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460122#M117048</link>
      <description>&lt;P&gt;The DevTools scoped application contains a number of helpful tools and scripts for reuse.&lt;/P&gt;
&lt;P&gt;To parse a URL and its parameters on the server side (within a script include, business rule or any other server side script) these two functions come in handy:&lt;/P&gt;
&lt;P&gt;ParseURL&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/saschawildgrube/servicenow-devtools/blob/master/update/sys_script_include_cc2cdcc01b1ff490edf3642aab4bcb26.xml"&gt;https://github.com/saschawildgrube/servicenow-devtools/blob/master/update/sys_script_include_cc2cdcc01b1ff490edf3642aab4bcb26.xml&amp;nbsp;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;ParseUrlParameters&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/saschawildgrube/servicenow-devtools/blob/master/update/sys_script_include_64e9ed441b73b450edf3642aab4bcb24.xml"&gt;https://github.com/saschawildgrube/servicenow-devtools/blob/master/update/sys_script_include_64e9ed441b73b450edf3642aab4bcb24.xml&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Enjoy!&lt;/P&gt;</description>
      <pubDate>Thu, 03 Feb 2022 17:22:19 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/get-values-from-url/m-p/1460122#M117048</guid>
      <dc:creator>saschawildg</dc:creator>
      <dc:date>2022-02-03T17:22:19Z</dc:date>
    </item>
  </channel>
</rss>

