Using document.querySelector for Service Portal
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-27-2024 03:46 AM
Is there any alternate to use document.querySelector for Service Portal and esc portal.
DOM Manipulation is not supported on Service Portal.
Can anyone please suggest alternate approach for it
Below is the code -
var requestedForName = g_form.getControl('onbehalf_name').id;
var requestedForNameSelector = "a[id*=" + '"lookup.' + requestedForName + '"]';
var requestedForNameRef = document.querySelector(requestedForNameSelector);
if(requestedForNameRef.style.display != "none")
requestedForNameRef.style.display = "none";
Thanks in advance
1 REPLY 1
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-28-2024 04:54 AM
We are also facing same issue. Can anyone please suggest an alternate approach here without using DOM Manipulation.