Onenewspagegermany.php 795 Bytes
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<?php

namespace app\Models\parserSkripte;
use App\Models\Searchengine;
use App\Models\Result;

class Onenewspagegermany extends Searchengine 
{
	public $results = [];

	function __construct (\SimpleXMLElement $engine, $mh, $query, $time)
	{
		parent::__construct($engine, $mh, $query, $time);
	}

	public function loadResults ()
	{
		$result = curl_multi_getcontent($this->ch);
		foreach( explode("\n", $result) as $line )
		{
			$line = trim($line);
			if( strlen($line) > 0 ){
				# Hier bekommen wir jedes einzelne Ergebnis
				$result = explode("|", $line);
				$this->results[] = new Result(
					trim(strip_tags($result[0])),
					$result[2],
					$result[2],
					$result[1],
					"<a href=\"http://www.newsdeutschland.com/videos.htm\">newsdeutschland.com</a>"
					);
			}
			
		}

	}
}