Adiciona Nexo Jornal

master
CaioWzy 2017-10-18 20:50:25 -03:00
parent c506f9f94e
commit 7cfe459667
No known key found for this signature in database
GPG Key ID: 78F3D5B09AA574ED
4 changed files with 21 additions and 3 deletions

View File

@ -37,6 +37,21 @@ else if (/gauchazh.clicrbs.com.br/.test(document.location.host)) {
sessionStorage.clear();';
}
else if (/www.nexojornal.com.br/.test(document.location.host)) {
code = "paywallContainer = document.getElementsByClassName('new-paywall-container')[0];\
paywallContent = paywallContainer.getAttribute('data-paywall-content');\
nexoApiURL = paywallContainer.getAttribute('data-paywall-check');\
xmlhttp = new XMLHttpRequest();\
xmlhttp.onreadystatechange = function() {\
if (this.readyState == 4 && (this.status == 200 || this.status == 201 || this.status == 401)) {\
access_token = JSON.parse(this.responseText)['access_token'];\
paywallContainer.className = 'wf-placeholder';\
paywallContainer.setAttribute('data-loadURL', paywallContent.replace('{access_token}', access_token));\
paywallContainer.setAttribute('data-skip-profiles', '');\
WFLazyLoader.loadFragment()}};\
xmlhttp.open('GET', nexoApiURL, true);\
xmlhttp.send();";
}
if (code !== null) {
var script = document.createElement('script');

View File

@ -24,7 +24,8 @@
"*://*.folha.uol.com.br/*",
"*://*.folha.com.br/*",
"*://*.ft.com/*",
"*://gauchazh.clicrbs.com.br/*"
"*://gauchazh.clicrbs.com.br/*",
"*://www.nexojornal.com.br/*"
]
}],

View File

@ -24,7 +24,8 @@
"*://*.folha.uol.com.br/*",
"*://*.folha.com.br/*",
"*://*.ft.com/*",
"*://gauchazh.clicrbs.com.br/*"
"*://gauchazh.clicrbs.com.br/*",
"*://www.nexojornal.com.br/*"
]
}],

View File

@ -24,7 +24,8 @@
"*://*.folha.uol.com.br/*",
"*://*.folha.com.br/*",
"*://*.ft.com/*",
"*://gauchazh.clicrbs.com.br/*"
"*://gauchazh.clicrbs.com.br/*",
"*://www.nexojornal.com.br/*"
]
}],