Fix TheTimes.co.uk (epaper)
This commit is contained in:
parent
8b0ad0ca6c
commit
1b05bc7090
@ -64,6 +64,7 @@ Visit the [Firefox repository](https://gitlab.com/magnolia1234/bypass-paywalls-f
|
||||
* Do not delete extension's folder from your computer/smartphone or Bypass Paywalls Clean (in developer mode) will disappear at restart.
|
||||
* In Chrome/Opera/Brave to disable the developer mode extensions popup use the extensions toolbar menu (by default enabled in Chrome 87+ or (if available) enable (experimental) chrome flag: chrome://flags/#extensions-toolbar-menu)
|
||||
* You will be logged out for most of the sites you have checked.
|
||||
* Some sites need to redirect to an amp-page (add an exception in your amp2html extension).
|
||||
|
||||
### Update
|
||||
For crx-installation: check for updates (in chrome://extensions).\
|
||||
|
@ -7,7 +7,7 @@ var manifestData = ext_api.runtime.getManifest();
|
||||
var ext_name = manifestData.name;
|
||||
var ext_version = manifestData.version;
|
||||
|
||||
const cs_limit_except = ['elespanol.com', 'faz.net', 'inkl.com', 'nation.africa', 'nationalgeographic.com'];
|
||||
const cs_limit_except = ['elespanol.com', 'faz.net', 'inkl.com', 'nation.africa', 'nationalgeographic.com', 'thetimes.co.uk'];
|
||||
var currentTabUrl = '';
|
||||
var csDone = false;
|
||||
var optin_setcookie = false;
|
||||
@ -915,7 +915,7 @@ ext_api.webRequest.onBeforeSendHeaders.addListener(function(details) {
|
||||
var setReferer = false;
|
||||
var googlebotEnabled = matchUrlDomain(use_google_bot, details.url) &&
|
||||
!(matchUrlDomain('barrons.com', details.url) && enabledSites.includes('#options_disable_gb_barrons')) &&
|
||||
!(matchUrlDomain('thetimes.co.uk', details.url) && !details.url.match(/\/epaper\.thetimes\.co\.uk\//)) &&
|
||||
!(matchUrlDomain('thetimes.co.uk', details.url) && !details.url.match(/\/epaper\.thetimes\.co\.uk\/article\//)) &&
|
||||
!(matchUrlDomain('wsj.com', details.url) && enabledSites.includes('#options_disable_gb_wsj'));
|
||||
var bingbotEnabled = matchUrlDomain(use_bing_bot, details.url) &&
|
||||
!(matchUrlDomain('stratfor.com', details.url) && details.url.match(/(\/(\d){4}-([a-z]||-)+-forecast(-([a-z]|-)+)?|-forecast-(\d){4}-([a-z]|[0-9]||-)+)$/));
|
||||
|
@ -6,6 +6,7 @@ Remove The Logic (fix obsolete)
|
||||
Fix Australia News Corp (video-still)
|
||||
Fix La Tercera (js)
|
||||
Fix MIT Technology Review (TinyPass)
|
||||
Fix TheTimes.co.uk (epaper)
|
||||
Fix Times Literary Supplement (set referer Google)
|
||||
|
||||
* v2.5.4.0 (2022-01-30)
|
||||
@ -510,7 +511,7 @@ Fix Cors Anywhere (link to allow access)
|
||||
Fix Il Secolo XIX (amp)
|
||||
Fix Medium custom domains (meter)
|
||||
Fix Statista (premium)
|
||||
Fix The Times (puzzles)
|
||||
Fix TheTimes.co.uk (puzzles)
|
||||
Update popup (not closing on switch/clear cookies)
|
||||
|
||||
* v2.0.7.0 (2021-02-07)
|
||||
|
@ -1784,10 +1784,11 @@ else if (matchDomain(['theathletic.com', 'theathletic.co.uk'])) {
|
||||
}
|
||||
|
||||
else if (matchDomain('thetimes.co.uk')) {
|
||||
let url = window.location.href;
|
||||
if (window.location.hostname !== 'epaper.thetimes.co.uk') {
|
||||
let block = document.querySelector('.subscription-block');
|
||||
let adverts = document.querySelectorAll('#ad-article-inline, #sticky-ad-header, div[class*="InlineAdWrapper"], div[class*="NativeAd"], div.responsiveweb-sc-1exejum-0');
|
||||
removeDOMElement(block, ...adverts);
|
||||
let url = window.location.href;
|
||||
let paywall = document.querySelector('div#paywall-portal-article-footer');
|
||||
if (paywall && !url.includes('?shareToken=')) {
|
||||
removeDOMElement(paywall);
|
||||
@ -1797,6 +1798,21 @@ else if (matchDomain('thetimes.co.uk')) {
|
||||
}
|
||||
let paywall_page = document.querySelector('div#paywall-portal-page-footer');
|
||||
removeDOMElement(paywall_page);
|
||||
} else {
|
||||
if (url.includes('/textview')) {
|
||||
function thetimes_link(node) {
|
||||
let article = node.closest('article[aid]');
|
||||
if (article)
|
||||
node.href = 'article/' + article.getAttribute('aid');
|
||||
}
|
||||
waitDOMElement('article[aid] > div > div > a.readmore.dis[href="javascript:void(0)"]', 'A', thetimes_link, true);
|
||||
csDoneOnce = true;
|
||||
} else {
|
||||
let pages = document.querySelectorAll('div.page-left, div.page-right');
|
||||
for (let page of pages)
|
||||
page.style.height = 'auto';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
else if (!matchDomain(['belfasttelegraph.co.uk', 'independent.ie']))
|
||||
@ -1845,7 +1861,7 @@ else if (matchDomain('elmercurio.com')) {
|
||||
elem.removeAttribute('style');
|
||||
let page_pdf_content = document.querySelector('div.page_pdf_content');
|
||||
let close_html = document.querySelector('div.close_html');
|
||||
removeDOMElement(page_pdf_content, close_html)
|
||||
removeDOMElement(page_pdf_content, close_html);
|
||||
}, 1000); // Delay (in milliseconds)
|
||||
window.setTimeout(function () {
|
||||
let cont_articlelight = document.querySelector('div.cont_articlelight');
|
||||
|
@ -39,5 +39,5 @@
|
||||
"webRequestBlocking",
|
||||
"<all_urls>"
|
||||
],
|
||||
"version": "2.5.4.2"
|
||||
"version": "2.5.4.3"
|
||||
}
|
||||
|
@ -600,5 +600,5 @@
|
||||
"*://*.wallkit.net/*",
|
||||
"*://*.wsj.net/*"
|
||||
],
|
||||
"version": "2.5.4.2"
|
||||
"version": "2.5.4.3"
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user