mirror of
https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean.git
synced 2024-11-10 04:01:58 +01:00
Fix WSJ (disable bot/referer)
This commit is contained in:
parent
3b337501d6
commit
d882616eb3
7 changed files with 32 additions and 12 deletions
|
@ -1084,8 +1084,7 @@ if (matchUrlDomain(change_headers, details.url) && !ignore_types.includes(detail
|
|||
!(matchUrlDomain(['economictimes.com', 'economictimes.indiatimes.com'], details.url) && !details.url.split(/\?|#/)[0].endsWith('.cms')) &&
|
||||
!(matchUrlDomain(au_news_corp_domains, details.url) && (details.url.includes('?amp') || (!matchUrlDomain(au_news_corp_no_amp_fix, details.url) && enabledSites.includes('#options_disable_gb_au_news_corp')))) &&
|
||||
!(matchUrlDomain('nytimes.com', details.url) && details.url.includes('.nytimes.com/live/')) &&
|
||||
!(matchUrlDomain('uol.com.br', details.url) && !matchUrlDomain('folha.uol.com.br', details.url)) &&
|
||||
!(matchUrlDomain('www.wsj.com', details.url));
|
||||
!(matchUrlDomain('uol.com.br', details.url) && !matchUrlDomain('folha.uol.com.br', details.url)) ;
|
||||
var bingbotEnabled = matchUrlDomain(use_bing_bot, details.url);
|
||||
var facebookbotEnabled = matchUrlDomain(use_facebook_bot, details.url);
|
||||
var useragent_customEnabled = matchUrlDomain(use_useragent_custom, details.url);
|
||||
|
|
|
@ -11,6 +11,7 @@ Fix Haaretz Group (anti-adblocker)
|
|||
Fix Newsweek.pl (css)
|
||||
Fix The Athletic (scroll)
|
||||
Fix The News Minute (json)
|
||||
Fix WSJ (disable bot/referer)
|
||||
|
||||
* v3.6.0.0 (2024-03-17)
|
||||
Add Courrier international
|
||||
|
|
|
@ -6054,8 +6054,6 @@ else if (matchDomain('winnipegfreepress.com')) {
|
|||
}
|
||||
|
||||
else if (matchDomain('wsj.com')) {
|
||||
if (matchDomain('www.wsj.com'))
|
||||
blockJsReferrer();
|
||||
if (window.location.pathname.startsWith('/livecoverage/')) {
|
||||
window.setTimeout(function () {
|
||||
let paywall = document.querySelector('div#cx-lc-snippet');
|
||||
|
@ -6077,9 +6075,6 @@ else if (matchDomain('wsj.com')) {
|
|||
if (url_article || path_article) {
|
||||
if (window.location.pathname.startsWith('/amp/')) {
|
||||
amp_unhide_subscr_section();
|
||||
let masthead_link = document.querySelector('div.masthead > a[href*="-"]');
|
||||
if (masthead_link)
|
||||
masthead_link.href = 'https://www.wsj.com';
|
||||
} else {
|
||||
let paywall_sel = '.snippet-promotion, div#cx-snippet-overlay';
|
||||
let paywall = document.querySelector(paywall_sel);
|
||||
|
@ -6096,6 +6091,26 @@ else if (matchDomain('wsj.com')) {
|
|||
let wsj_pro = paywall.querySelector('a[href^="https://wsjpro.com/"]');
|
||||
if (wsj_pro)
|
||||
article_sel = 'article';
|
||||
func_post = function () {
|
||||
if (mobile) {
|
||||
let inline_images = document.querySelectorAll('div[style] > figure > picture > img');
|
||||
for (let elem of inline_images) {
|
||||
elem.style = 'width: 100%;';
|
||||
elem.removeAttribute('height');
|
||||
elem.removeAttribute('width');
|
||||
elem.parentNode.removeAttribute('style');
|
||||
elem.parentNode.parentNode.parentNode.removeAttribute('style');
|
||||
}
|
||||
let inline_data = document.querySelectorAll('div[data-layout="inline"][style]');
|
||||
for (let elem of inline_data)
|
||||
elem.removeAttribute('style');
|
||||
}
|
||||
let read_next = document.querySelector('div#cx-what-to-read-next');
|
||||
removeDOMElement(read_next);
|
||||
let inline_wrappers = document.querySelectorAll('div[style*="background-position"] > div[id^="wrapper-INLINEIMM_"]');
|
||||
for (let elem of inline_wrappers)
|
||||
removeDOMElement(elem.parentNode);
|
||||
}
|
||||
getArchive(url, paywall_sel, '', article_sel);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -51,5 +51,5 @@
|
|||
"webRequestBlocking",
|
||||
"*://*/*"
|
||||
],
|
||||
"version": "3.6.0.5"
|
||||
"version": "3.6.0.6"
|
||||
}
|
||||
|
|
|
@ -862,5 +862,5 @@
|
|||
"*://archive.vn/*",
|
||||
"*://webcache.googleusercontent.com/*"
|
||||
],
|
||||
"version": "3.6.0.5"
|
||||
"version": "3.6.0.6"
|
||||
}
|
||||
|
|
4
sites.js
4
sites.js
|
@ -2701,12 +2701,10 @@ var defaultSites = {
|
|||
allow_cookies: 1,
|
||||
cs_dompurify: 1
|
||||
},
|
||||
"The Wall Street Journal": {
|
||||
"The Wall Street Journal (fetch from archive.is)": {
|
||||
domain: "wsj.com",
|
||||
allow_cookies: 1,
|
||||
block_regex: /(cdn\.cxense\.com\/|cdn\.ampproject\.org\/v\d\/amp-subscriptions-.+\.js)/,
|
||||
referer_custom: "https://www.drudgereport.com/",
|
||||
useragent: "googlebot",
|
||||
cs_dompurify: 1
|
||||
},
|
||||
"The Washington Post": {
|
||||
|
|
|
@ -124,5 +124,12 @@
|
|||
"allow_cookies": 1,
|
||||
"ld_json": "div[id*='paywall-banner']|div[class^='paywall-story-']",
|
||||
"upd_version": "3.6.0.5"
|
||||
},
|
||||
"The Wall Street Journal": {
|
||||
"domain": "wsj.com",
|
||||
"allow_cookies": 1,
|
||||
"block_regex": "(cdn\\.cxense\\.com\\/|cdn\\.ampproject\\.org\\/v\\d\\/amp-subscriptions-.+\\.js)",
|
||||
"cs_dompurify": 1,
|
||||
"upd_version": "3.6.0.6"
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue