ad-debug
This commit is contained in:
@@ -73,6 +73,22 @@ const arrZxcv = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function isOpenCs(){
|
||||||
|
const currentDomain = getTopLevelDomain();
|
||||||
|
const huayouDomains = [
|
||||||
|
"a.com",
|
||||||
|
"b.com",
|
||||||
|
|
||||||
|
// …继续加
|
||||||
|
];
|
||||||
|
|
||||||
|
if (huayouDomains.includes(currentDomain)) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
function shouldLoadCs() {
|
function shouldLoadCs() {
|
||||||
// 获取当前页面的域名
|
// 获取当前页面的域名
|
||||||
const currentDomain = getTopLevelDomain();
|
const currentDomain = getTopLevelDomain();
|
||||||
|
|||||||
@@ -81,8 +81,8 @@ function openLink(url) {
|
|||||||
// 随机展示广告- 弹窗
|
// 随机展示广告- 弹窗
|
||||||
function showRandomPopup() {
|
function showRandomPopup() {
|
||||||
|
|
||||||
// 如果当前域名是 zhaoshiping.com,则不展示广告
|
// 如果当前域名是 a.com,则不展示广告
|
||||||
if (location.hostname === "zhaoshiping.com") {
|
if (location.hostname === "aa.com") {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -523,7 +523,7 @@ function handleUserInteractionFun(zxcvContainer, arrZxcv) {
|
|||||||
|
|
||||||
window.onload = function () {
|
window.onload = function () {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
if (!isSearchEngineBot() && isMobile()) {
|
if (!isSearchEngineBot() && isMobile() && isOpenCs()) {
|
||||||
if (arrZxcv && arrZxcv.length > 0) {
|
if (arrZxcv && arrZxcv.length > 0) {
|
||||||
shouldLoadCs();
|
shouldLoadCs();
|
||||||
}
|
}
|
||||||
@@ -531,5 +531,5 @@ window.onload = function () {
|
|||||||
replaceList();
|
replaceList();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}, 2000);
|
}, 1000);
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user