Skip to main content
Ex Libris Knowledge Center

How to redirect old domain name full length URL (including view)?

  • Product: Primo



How to redirect old domain name full length URL (including view)?


Inorder to redirect the FE url that starts with the old domain ( to new domain (

Primo Home > Advanced Configuration > All Mapping Tables
Sub System: FRONTEND
Table Name:  Front-End Redirect Definitions
with this table, DNS: will be successfully redirected to

But it is not the same with the old domain name full length URL's (which includes view) and are not getting redirected to the new domain.

For Example: is bookmarked by a student and this link cannot be redirected to the new domain using the Front-End Redirect Definitions Mapping table.

In such a case, this old domain name full length URL (including view) can be redirected by using custom.JS file from the customer end.

Please add a condition to your Custom.JS file checking something like this: "if the url contains the old domain name --> then --> window.location.replace("redirection link");"
For example: Check this JS script matching this requirement. Change it according to your requirement.
if(window.location.href.indexOf("") > -1) {
} //This is just an example (may be not the exact working script). You need to script it accordingly.

Unfortunately providing CSS and or JS/AngularJS code for Primo New UI customization is out of support's scope.



  • Article last edited: 06-Jun-2020