Mobile 1668 to Desktop

Auto Redirect from mobile 1668 to desktop

// ==UserScript==
// @name         Mobile 1668 to Desktop
// @namespace    https://www.reddit.com/user/RobotOilInc
// @version      0.1.1
// @description  Auto Redirect from mobile 1668 to desktop
// @author       RobotOilInc
// @match        https://m.1688.com/offer/*.html*offerId=*
// @match        https://m.1688.com/offer/*.html*
// @license      MIT
// @homepageURL  https://gf.qytechs.cn/en/scripts/430178-mobile-1668-to-desktop
// @supportURL   https://gf.qytechs.cn/en/scripts/430178-mobile-1668-to-desktop
// @run-at       document-start
// @icon         https://img.alicdn.com/tfs/TB1uh..zbj1gK0jSZFuXXcrHpXa-16-16.ico?x-icon
// ==/UserScript==

/* jshint esversion: 6 */

// Regex to grab offerId if not in URL
const regex = /https?:\/\/m\.1688\.com\/offer\/(.*)\.html/i;

// Get the offerId
let offerId = (new URLSearchParams(window.location.search)).get('offerId');
if (offerId == null) {
    offerId = regex.exec(window.location.href)[1]
}

window.location.href = `https://detail.1688.com/offer/${offerId}.html`;

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址