Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var url = window.location.href;
- var oldUrl = "http://oldurl.tumblr.com/";
- var newUrl = "http://itsmemacleod.tumblr.com/";
- // Split fucking Query strings
- var splitString = oldUrl.substr(url.indexOf(oldUrl) + 1);
- if (splitString.length > 1) {
- // New Url With Query strings
- newUrl = newUrl + splitString;
- }
- window.location.replace(newUrl)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement