Hide/disable the Printer Friendly Version icon
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2022 12:30 AM
I have a requirement to remove or hide the 'Printer friendly version' option from within settings (the cog at the top right of the screen).
We tried a UI Script to accomplish this which somewhat works. When a user goes to the cog the printing option is hidden, but if the user changes their selection from the 'general' tab to another option, then back to 'general', the 'printer friendly version' option is back.
In lieu of a system property which doesn't exist, is anyone able to suggest a method to permanently hide it?
Current UI Script:
addLoadEvent(removeIcon);
function removePrint() {
try {
if($j("printer-friendly")) {
$j('printer-friendly', parent.document).hide();
}
} catch (e) {
//
}
}
- Labels:
-
User Experience and Design

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2022 04:00 AM
Hi James,
Try this code on the ui script:
Event.observe(window, 'load', function() {
var x= $$('a')[9];
x.style.display = 'none';
});
Please, don't forget to mark my answer as correct if it solves your issue or mark it as helpful if it is relevant for you!
Best Regards,
Filipe Cruz
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2022 10:05 PM
Thanks Filipe
I should have mentioned in my original post that I had already tried that solution. I saw that exact code in a 9yr old post from yonu29. It doesn't work, unfortunately.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2022 10:17 PM
Hi,
Inform your customer that this is not recommended and nothing exists OOB to hide it always.
I won't recommend using DOM manipulation to hide it even if it works as using DOM is not good practice.
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2022 10:22 PM
Yep, I'm well aware of that and have indeed had those conversations. There are security considerations which I can't get into.
I may have to look at logging to see if at the very least we can log anytime the feature is used.