mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-13 15:05:56 +00:00
fix toothpastefordinner valiant efforts to prevent scraping
This commit is contained in:
@@ -6,12 +6,15 @@ class Af_Comics_Tfd extends Af_ComicFilter {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function process(&$article) {
|
function process(&$article) {
|
||||||
$owner_uid = $article["owner_uid"];
|
|
||||||
|
|
||||||
if (strpos($article["link"], "toothpastefordinner.com") !== FALSE) {
|
if (strpos($article["link"], "toothpastefordinner.com") !== FALSE) {
|
||||||
$doc = new DOMDocument();
|
$res = fetch_file_contents($article["link"], false, false, false,
|
||||||
|
false, false, 0,
|
||||||
|
"Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.1; WOW64; Trident/6.0)");
|
||||||
|
|
||||||
@$doc->loadHTML(fetch_file_contents($article["link"]));
|
if (!$res) return $article;
|
||||||
|
|
||||||
|
$doc = new DOMDocument();
|
||||||
|
$doc->loadHTML($res);
|
||||||
|
|
||||||
$basenode = false;
|
$basenode = false;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user