mirror of
https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean.git
synced 2024-09-20 04:43:42 +02:00
Add Irish Independent
This commit is contained in:
parent
02f03905a8
commit
4d04b3f1fc
5 changed files with 26 additions and 17 deletions
|
@ -150,6 +150,7 @@ Install add-on by downloading xpi-file.
|
||||||
##### United Kingdom/Ireland
|
##### United Kingdom/Ireland
|
||||||
[Financial News](https://www.fnlondon.com) -
|
[Financial News](https://www.fnlondon.com) -
|
||||||
[Financial Times](https://www.ft.com) -
|
[Financial Times](https://www.ft.com) -
|
||||||
|
[Irish Independent](https://www.independent.ie) -
|
||||||
[London Review of Books](https://www.lrb.co.uk) -
|
[London Review of Books](https://www.lrb.co.uk) -
|
||||||
[The Athletic UK](https://theathletic.com) -
|
[The Athletic UK](https://theathletic.com) -
|
||||||
[The Economist](https://www.economist.com) -
|
[The Economist](https://www.economist.com) -
|
||||||
|
|
|
@ -41,6 +41,7 @@ var allow_cookies = [
|
||||||
'handelsblatt.com',
|
'handelsblatt.com',
|
||||||
'heraldsun.com.au',
|
'heraldsun.com.au',
|
||||||
'humo.be',
|
'humo.be',
|
||||||
|
'independent.ie',
|
||||||
'intelligentinvestor.com.au',
|
'intelligentinvestor.com.au',
|
||||||
'kleinezeitung.at',
|
'kleinezeitung.at',
|
||||||
'lc.nl',
|
'lc.nl',
|
||||||
|
@ -170,6 +171,7 @@ var blockedRegexes = {
|
||||||
'haaretz.com': /haaretz\.com\/hdc\/web\/js\/minified\/header-scripts-int.js.+/,
|
'haaretz.com': /haaretz\.com\/hdc\/web\/js\/minified\/header-scripts-int.js.+/,
|
||||||
'historyextra.com': /.+\.evolok\.net\/.+\/authorize\/.+/,
|
'historyextra.com': /.+\.evolok\.net\/.+\/authorize\/.+/,
|
||||||
'ilmessaggero.it': /(utils\.cedsdigital\.it\/js\/PaywallMeter\.js|static\.viralize\.tv\/viralize_player)/,
|
'ilmessaggero.it': /(utils\.cedsdigital\.it\/js\/PaywallMeter\.js|static\.viralize\.tv\/viralize_player)/,
|
||||||
|
'independent.ie': /cdn\.flip-pay\.com\/clients\/inm\/flip-pay\.js/,
|
||||||
'inquirer.com': /.+\.tinypass\.com\/.+/,
|
'inquirer.com': /.+\.tinypass\.com\/.+/,
|
||||||
'ladepeche.fr': /.+\.poool\.fr\/.+/,
|
'ladepeche.fr': /.+\.poool\.fr\/.+/,
|
||||||
'lastampa.it': /.+\.repstatic\.it\/minify\/sites\/lastampa\/.+\/config\.cache\.php\?name=social_js/,
|
'lastampa.it': /.+\.repstatic\.it\/minify\/sites\/lastampa\/.+\/config\.cache\.php\?name=social_js/,
|
||||||
|
|
|
@ -71,7 +71,7 @@ else if (matchDomain('telegraaf.nl')) {
|
||||||
removeDOMElement(article_body_old);
|
removeDOMElement(article_body_old);
|
||||||
let json = document.querySelector('script[type="application/ld+json"][data-react-helmet="true"]');
|
let json = document.querySelector('script[type="application/ld+json"][data-react-helmet="true"]');
|
||||||
if (json) {
|
if (json) {
|
||||||
json_text = JSON.parse(json.text).articleBody;
|
var json_text = JSON.parse(json.text).articleBody;
|
||||||
let article_body = document.querySelector('section.TextArticlePage__bodyText');
|
let article_body = document.querySelector('section.TextArticlePage__bodyText');
|
||||||
if (article_body) {
|
if (article_body) {
|
||||||
let div_main = document.createElement("div");
|
let div_main = document.createElement("div");
|
||||||
|
@ -540,8 +540,7 @@ else if (matchDomain('barrons.com')) {
|
||||||
href = signin_links[i].href;
|
href = signin_links[i].href;
|
||||||
if (href.includes('target=')) {
|
if (href.includes('target=')) {
|
||||||
href = href.split('target')[1].split('%3F')[0];
|
href = href.split('target')[1].split('%3F')[0];
|
||||||
href = href.replace('=', '').replace('%3A', ':');
|
href = href.replace('=', '').replace('%3A', ':').replace(/%2F/g, '/');
|
||||||
href = href.replace('%2F', '/').replace('%2F', '/').replace('%2F', '/').replace('%2F', '/');
|
|
||||||
signin_links[i].href = href;
|
signin_links[i].href = href;
|
||||||
signin_links[i].text = 'Click';
|
signin_links[i].text = 'Click';
|
||||||
}
|
}
|
||||||
|
@ -675,9 +674,9 @@ else if (matchDomain('spectator.co.uk')) {
|
||||||
}
|
}
|
||||||
|
|
||||||
else if (matchDomain('bostonglobe.com')) {
|
else if (matchDomain('bostonglobe.com')) {
|
||||||
if (!document.cookie.split(';').some(function(item) { return item.trim().indexOf('s_fid=') === 0 })) {
|
if (!cookieExists('s_fid')) {
|
||||||
let s_fid = genHexString(16) + '-' + genHexString(16);
|
let s_fid = genHexString(16) + '-' + genHexString(16);
|
||||||
document.cookie = "s_fid=" + s_fid + "; domain=bostonglobe.com; path=/; max-age=1209600";
|
setCookie('s_fid', s_fid, 'bostonglobe.com', '/', 14);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -694,6 +693,12 @@ else if (matchDomain('historyextra.com')) {
|
||||||
removeDOMElement(ad_banner);
|
removeDOMElement(ad_banner);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
else if (matchDomain('independent.ie')) {
|
||||||
|
if (!cookieExists('subscriber')) {
|
||||||
|
setCookie('subscriber', '{"subscriptionStatus": true}', 'www.independent.ie', '/', 14);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// General Functions
|
// General Functions
|
||||||
function removeDOMElement(...elements) {
|
function removeDOMElement(...elements) {
|
||||||
for (let element of elements) {
|
for (let element of elements) {
|
||||||
|
@ -720,6 +725,15 @@ function removeClassesByPrefix(el, prefix) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function cookieExists(name) {
|
||||||
|
return document.cookie.split(';').some(function(item) { return item.trim().indexOf(name + '=') === 0 })
|
||||||
|
}
|
||||||
|
|
||||||
|
function setCookie(name, value, domain, path, days) {
|
||||||
|
var max_age = days * 24 * 60 * 60;
|
||||||
|
document.cookie = name + "=" + (value || "") + "; domain=" + domain + "; path=" + path + "; max-age=" + max_age;
|
||||||
|
}
|
||||||
|
|
||||||
function genHexString(len) {
|
function genHexString(len) {
|
||||||
let output = '';
|
let output = '';
|
||||||
for (let i = 0; i < len; i++) {
|
for (let i = 0; i < len; i++) {
|
||||||
|
|
|
@ -3,17 +3,6 @@
|
||||||
"scripts": ["sites.js", "background.js"]
|
"scripts": ["sites.js", "background.js"]
|
||||||
},
|
},
|
||||||
"content_security_policy": "script-src 'self'; object-src 'self'",
|
"content_security_policy": "script-src 'self'; object-src 'self'",
|
||||||
"content_scripts": [{
|
|
||||||
"matches": [
|
|
||||||
"*://*.bloomberg.com/*",
|
|
||||||
"*://*.economist.com/*",
|
|
||||||
"*://*.nytimes.com/*",
|
|
||||||
"*://*.theathletic.com/*",
|
|
||||||
"*://*.washingtonpost.com/*"
|
|
||||||
],
|
|
||||||
"js": ["contentScript.js"]
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"applications": {
|
"applications": {
|
||||||
"gecko": {
|
"gecko": {
|
||||||
"id": "magnolia_limited_permissions@12.34",
|
"id": "magnolia_limited_permissions@12.34",
|
||||||
|
@ -123,6 +112,7 @@
|
||||||
"*://*.ilmanifesto.it/*",
|
"*://*.ilmanifesto.it/*",
|
||||||
"*://*.ilmessaggero.it/*",
|
"*://*.ilmessaggero.it/*",
|
||||||
"*://*.inc.com/*",
|
"*://*.inc.com/*",
|
||||||
|
"*://*.independent.ie/*",
|
||||||
"*://*.inquirer.com/*",
|
"*://*.inquirer.com/*",
|
||||||
"*://*.intelligentinvestor.com.au/*",
|
"*://*.intelligentinvestor.com.au/*",
|
||||||
"*://*.irishtimes.com/*",
|
"*://*.irishtimes.com/*",
|
||||||
|
@ -244,7 +234,9 @@
|
||||||
"*://*.ampproject.org/*",
|
"*://*.ampproject.org/*",
|
||||||
"*://*.cedsdigital.it/*",
|
"*://*.cedsdigital.it/*",
|
||||||
"*://*.corriereobjects.it/*",
|
"*://*.corriereobjects.it/*",
|
||||||
|
"*://*.emol.cl/*",
|
||||||
"*://*.epimg.net/*",
|
"*://*.epimg.net/*",
|
||||||
|
"*://*.flip-pay.com/*",
|
||||||
"*://*.htmedia.in/*",
|
"*://*.htmedia.in/*",
|
||||||
"*://*.lightboxcdn.com/*",
|
"*://*.lightboxcdn.com/*",
|
||||||
"*://*.lp4.io/*",
|
"*://*.lp4.io/*",
|
||||||
|
@ -254,7 +246,6 @@
|
||||||
"*://*.repstatic.it/*",
|
"*://*.repstatic.it/*",
|
||||||
"*://*.userzoom.com/*",
|
"*://*.userzoom.com/*",
|
||||||
"*://*.viralize.tv/*",
|
"*://*.viralize.tv/*",
|
||||||
"*://merreader.emol.cl/*",
|
|
||||||
"*://*.bndestem.nl/*",
|
"*://*.bndestem.nl/*",
|
||||||
"*://*.bd.nl/*",
|
"*://*.bd.nl/*",
|
||||||
"*://*.ed.nl/*",
|
"*://*.ed.nl/*",
|
||||||
|
|
1
sites.js
1
sites.js
|
@ -64,6 +64,7 @@ var defaultSites =
|
||||||
"Il Messaggero": "ilmessaggero.it",
|
"Il Messaggero": "ilmessaggero.it",
|
||||||
"Illawarra Mercury": "illawarramercury.com.au",
|
"Illawarra Mercury": "illawarramercury.com.au",
|
||||||
"Intelligent Investor": "intelligentinvestor.com.au",
|
"Intelligent Investor": "intelligentinvestor.com.au",
|
||||||
|
"Irish Independent": "independent.ie",
|
||||||
"Kleine Zeitung": "kleinezeitung.at",
|
"Kleine Zeitung": "kleinezeitung.at",
|
||||||
"L'Écho": "lecho.be",
|
"L'Écho": "lecho.be",
|
||||||
"L'Opinion": "lopinion.fr",
|
"L'Opinion": "lopinion.fr",
|
||||||
|
|
Loading…
Reference in a new issue