Fix indentation and remove empty lines

This commit is contained in:
logmanoriginal 2016-08-03 20:14:59 +02:00
parent 2a02023c8a
commit 83d7f138ed

View file

@ -2,13 +2,11 @@
class LeJournalDuGeekBridge extends BridgeAbstract{
public function loadMetadatas() {
$this->maintainer = "polopollo";
$this->name = "journaldugeek.com (FR)";
$this->uri = "http://www.journaldugeek.com/";
$this->description = "Returns the 5 newest posts from LeJournalDuGeek (full text).";
$this->update = "2016-08-03";
}
function LeJournalDuGeekStripCDATA($string) {
@ -20,12 +18,14 @@ class LeJournalDuGeekBridge extends BridgeAbstract{
function LeJournalDuGeekExtractContent($url) {
$articleHTMLContent = $this->file_get_html($url);
$text = $text.$articleHTMLContent->find('div.post-content', 0)->innertext;
foreach($articleHTMLContent->find('a.more') as $element) {
if ($element->innertext == "Source") {
$text = $text . '<p><a href="' . $element->href . '">Source : ' . $element->href . '</a></p>';
break;
}
}
foreach($articleHTMLContent->find('iframe') as $element) {
if (preg_match("/youtube/i", $element->src)) {
$text = $text . '// An IFRAME to Youtube was included in the article: <a href="' . $element->src . '">' . $element->src . '</a><br>';
@ -51,7 +51,6 @@ class LeJournalDuGeekBridge extends BridgeAbstract{
$limit++;
}
}
}
public function getName(){