您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Redirect Chinese Bing to International Bing
// ==UserScript== // @name Automatic Redirection from Chinese Bing to International Bing // @namespace https://www.tampermonkey.net/ // @version 1.5 // @description Redirect Chinese Bing to International Bing // @author Greasy Fork // @license MIT // @match https://cn.bing.com/* // @match https://www.bing.com/* // @match https://global.bing.com/* // @match https://bing.com/* // @icon https://www.google.com/s2/favicons?sz=64&domain=bing.com // @grant none // ==/UserScript== (function () { 'use strict'; const redirectUrl = (url) => { let updatedUrl = new URL(url); updatedUrl.hostname = 'global.bing.com'; updatedUrl.searchParams.set('setmkt', 'en-US'); updatedUrl.searchParams.set('setlang', 'en-US'); updatedUrl.searchParams.set('cc', 'US'); return updatedUrl.href; }; const currentUrl = window.location.href; const isGlobalBing = currentUrl === 'https://global.bing.com/?scope=web&cc=US' || currentUrl.startsWith('https://global.bing.com/account'); if (!isGlobalBing) { window.location.replace(redirectUrl(currentUrl)); } document.body.innerHTML = document.body.innerHTML.replace( /cn.bing.com/g, 'global.bing.com' ); })();