How to Get paremeter value from public survey url

JackieZhang
Kilo Sage

I have a req for adding the read only question User Name to a public survey. the value of User Name need to get from URL. how to implement it? 

8 REPLIES 8

Here is my url for access public survey https://xxx.service-now.com/esc?id=public_survey&type_id=e95e906bfbe3b2503c67f6026eefdcb7&name=jacki...

And I get the value from url and set in survey

 
 

 

 

Snipaste_2026-03-17_00-07-14.png

@JackieZhang 

then you can do this

-> create a custom widget and add it in that OOTB portal page

-> in that custom widget use DOM manipulation and set the name field with logged in user.

logic is shared in the other link I shared earlier.

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

Yes,the only way I think, But I want to know if I can use publich_survey page and use client script to get it.