Skip to content

Instantly share code, notes, and snippets.

@dhcole
Created August 25, 2021 20:50
Show Gist options
  • Save dhcole/18c2a9779b77ba9f46a3417d22a4c1f6 to your computer and use it in GitHub Desktop.
Save dhcole/18c2a9779b77ba9f46a3417d22a4c1f6 to your computer and use it in GitHub Desktop.
var oldDomain = "businessnj.webflow.io";
var newDomain = "business.nj.gov";
if (location.hostname === oldDomain) {
location.replace("https://" + newDomain + location.pathname + location.search);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment