From c75622135eb606603b725869aa8c1426cc296eb7 Mon Sep 17 00:00:00 2001 From: Mitsukarenai Date: Tue, 2 Aug 2016 14:24:54 +0200 Subject: [PATCH] [DailymotionBridge] fix --- bridges/ArstechnicaBridge.php | 158 +++++++++++++++++----------------- bridges/DailymotionBridge.php | 6 +- 2 files changed, 82 insertions(+), 82 deletions(-) diff --git a/bridges/ArstechnicaBridge.php b/bridges/ArstechnicaBridge.php index f9a7398..de26ee1 100644 --- a/bridges/ArstechnicaBridge.php +++ b/bridges/ArstechnicaBridge.php @@ -1,79 +1,79 @@ -maintainer = "prysme"; - $this->name = "ArstechnicaBridge"; - $this->uri = "http://arstechnica.com"; - $this->description = "The PC enthusiast's resource. Power users and the tools they love, without computing religion"; - $this->update = "01/08/2016"; - - } - - public function collectData(array $param) { - function StripWithDelimiters($string, $start, $end) { - while (strpos($string, $start) !== false) { - $section_to_remove = substr($string, strpos($string, $start)); - $section_to_remove = substr($section_to_remove, 0, strpos($section_to_remove, $end) + strlen($end)); - $string = str_replace($section_to_remove, '', $string); - } return $string; - } - function StripCDATA($string) { - $string = str_replace('', '', $string); - return $string; - } - - function ExtractContent($url) { - #echo $url; - $html2 = file_get_html($url); - - $text = $html2->find("section[id='article-guts']", 0); - /*foreach ($text->find('