How to Update the Catalog form link which should redirect to different portal

girija04
Tera Contributor

I am working on a customization in the ServiceNow Employee Center portal. Currently, when users search for a form using the search bar, the results open and direct to fill the form. But now i need the form itself to redirect to different portal.

 

Could someone guide me on how to update the form links so that they redirect to a different portal and open in the form view? 
Any step-by-step instructions or references to relevant documentation would be greatly appreciated.

 

Thank you!

2 REPLIES 2

Alp Utku
Mega Sage

Sumanth16
Kilo Patron

Hi @girija04 ,

 

You could add an onLoad Catalog Client Script that would redirect to either a new Content Item Catalog Item that includes a description that the item is no longer active and links to the Category individual items or redirect directly to the Category with the new items.

 

It could look like:

 

function onLoad() {
   //Type appropriate comment here, and begin script below
   top.window.location = "sp?id=sc_category&sys_id=replace your sysid";
}

 

 

You just need to make sure the "Isolate script" field is set to "false" and that it is set to run in the Portal.  This kind of thing is frowned upon, but sometimes you just have to do what you have to do.

 

Just deactivating the old items is not very friendly.  But, make sure you clear the Catalogs and Category field on the items so they would no longer be found within the Catalog.

 

The Content Item is probably more user-friendly as the user would see the message.  You could even tell them to remove any bookmarks to the old items.  It's basically a Catalog Item that cannot be ordered.

 

Plz mark my solution as Accept, If you find it helpful.

 

 

Thanks & Regards,

Sumanth meda