diff --git a/status-pages/dhl_redirect_tracking_page.user.js b/status-pages/dhl_redirect_tracking_page.user.js new file mode 100644 index 0000000..dc0f7cc --- /dev/null +++ b/status-pages/dhl_redirect_tracking_page.user.js @@ -0,0 +1,23 @@ +// ==UserScript== +// @name Redirect DHL tracking page +// @description Redirects to a more static version of the tracking page that doesn't reset after a short time. +// @version 2019.06.04.1 +// @author tastytea +// @copyright 2019, tastytea (https://tastytea.de/) +// @license GPL-3.0-only +// @namespace tastytea.de +// @homepageURL https://schlomp.space/tastytea/userscripts +// @supportURL https://schlomp.space/tastytea/userscripts/issues +// @downloadURL https://schlomp.space/tastytea/userscripts/raw/branch/main/status-pages/dhl_redirect_tracking_page.user.js +// @grant none +// @match https://*.dhl.de/*idc=* +// @run-at document-end +// @inject-into content +// ==/UserScript== + +var re = new RegExp('dhl\.de/([^/]+)/.+idc=([0-9]+)'); +var result = re.exec(window.location.href); +var lang = result[1]; +var idc = result[2]; + +window.location.assign("https://nolp.dhl.de/nextt-online-public/" + lang + "/search?piececode=" + idc);