]> git.mxchange.org Git - friendica-addons.git/blobdiff - leistungsschutzrecht/leistungsschutzrecht.php
Revert to stable version 3.5.4
[friendica-addons.git] / leistungsschutzrecht / leistungsschutzrecht.php
index 60ca9b8b2dce3a6fa751de2d771e37c5c7360edb..c58c707f0275647b29f426dcbcf03f4fda670bb5 100644 (file)
@@ -66,6 +66,23 @@ function leistungsschutzrecht_cuttext($text) {
 function leistungsschutzrecht_fetchsites() {
        require_once("include/network.php");
 
+       // This list works - but question is how current it is
+       $url = "http://leistungsschutzrecht-stoppen.d-64.org/blacklist.txt";
+       $sitelist = fetch_url($url);
+       $siteurls = explode(',', $sitelist);
+
+       $whitelist = array('tagesschau.de', 'heute.de', 'wdr.de');
+
+       $sites = array();
+       foreach ($siteurls AS $site) {
+               if (!in_array($site, $whitelist)) {
+                       $sites[$site] = $site;
+               }
+       }
+
+       // I would prefer parsing the list from the original site, but I haven't found a list.
+       // The following stays here to possibly reenable it in the future without having to reinvent the wheel completely.
+/*
        $sites = array();
 
        $url = "http://www.vg-media.de/lizenzen/digitale-verlegerische-angebote/wahrnehmungsberechtigte-digitale-verlegerische-angebote.html";
@@ -95,6 +112,7 @@ function leistungsschutzrecht_fetchsites() {
                        }
                }
        }
+*/
 
        if (sizeof($sites)) {
                set_config('leistungsschutzrecht','sites',$sites);