\$sp.getParameter("table")

amaneet
Kilo Contributor

May i know what is the use of   $sp.getParameter("table") in widgets?

How does it take a value?

Thanks

3 REPLIES 3

divya mishra
Tera Guru

Hi Amaneet,



The $sp.getParameter() method retrieves the sys_id from the request querystring. You may require to use $sp.getParameter("sys_id") in this case.


More more reference use the below link :


https://docs.servicenow.com/bundle/jakarta-servicenow-platform/page/build/service-portal/task/embed-...



Let me know if this was useful/correct


Have a great day ahead



Regards,


Divya Mishra


Inactive_Us1474
Giga Guru

$sp global object refers to methods of GlideSPScriptable API.


Refer the below link :


https://developer.servicenow.com/app.do#!/api_doc?v=jakarta&id=r_GSPS-getParameter_S


Dhyanendra
Tera Contributor

It returns the value of a given key from the query string i.e. whatever the value of "table" will be returned using this method.

 

Please mark it as helpful , if it helped you.