Skip to content
Snippets Groups Projects
Commit 81e200a1 authored by Dominik Hebeler's avatar Dominik Hebeler
Browse files

Fixed a bug in parser scripts

parent 087c4fe4
No related branches found
No related tags found
No related merge requests found
...@@ -69,7 +69,7 @@ class Europeana extends Searchengine ...@@ -69,7 +69,7 @@ class Europeana extends Searchengine
} }
$next = new Europeana($this->engine, $metager); $next = new Europeana($this->engine, $metager);
$next->getString .= "&start=" . $start; $next->getString .= "&start=" . $start;
$next->hash = md5($next->host . $next->getString . $next->port . $next->name); $next->hash = md5($next->engine->host . $next->getString . $next->engine->port . $next->name);
$this->next = $next; $this->next = $next;
} catch (\Exception $e) { } catch (\Exception $e) {
Log::error("A problem occurred parsing results from $this->name:"); Log::error("A problem occurred parsing results from $this->name:");
......
...@@ -65,7 +65,7 @@ class Flickr extends Searchengine ...@@ -65,7 +65,7 @@ class Flickr extends Searchengine
} }
$next = new Flickr($this->name, $this->engine, $metager); $next = new Flickr($this->name, $this->engine, $metager);
$next->getString .= "&page=" . $page; $next->getString .= "&page=" . $page;
$next->hash = md5($next->host . $next->getString . $next->port . $next->name); $next->hash = md5($next->engine->host . $next->getString . $next->engine->port . $next->name);
$this->next = $next; $this->next = $next;
} catch (\Exception $e) { } catch (\Exception $e) {
Log::error("A problem occurred parsing results from $this->name:"); Log::error("A problem occurred parsing results from $this->name:");
......
...@@ -58,7 +58,7 @@ class Onenewspage extends Searchengine ...@@ -58,7 +58,7 @@ class Onenewspage extends Searchengine
$next->resultCount = $this->resultCount; $next->resultCount = $this->resultCount;
$next->offset = $this->offset + $this->resultCount; $next->offset = $this->offset + $this->resultCount;
$next->getString .= "&o=" . $next->offset; $next->getString .= "&o=" . $next->offset;
$next->hash = md5($next->host . $next->getString . $next->port . $next->name); $next->hash = md5($next->engine->host . $next->getString . $next->engine->port . $next->name);
$this->next = $next; $this->next = $next;
} }
} }
...@@ -63,7 +63,7 @@ class Onenewspagegermany extends Searchengine ...@@ -63,7 +63,7 @@ class Onenewspagegermany extends Searchengine
$next->resultCount = $this->resultCount; $next->resultCount = $this->resultCount;
$next->offset = $this->offset + $this->resultCount; $next->offset = $this->offset + $this->resultCount;
$next->getString .= "&o=" . $next->offset; $next->getString .= "&o=" . $next->offset;
$next->hash = md5($next->host . $next->getString . $next->port . $next->name); $next->hash = md5($next->engine->host . $next->getString . $next->engine->port . $next->name);
$this->next = $next; $this->next = $next;
} }
} }
...@@ -56,7 +56,7 @@ class Onenewspagevideo extends Searchengine ...@@ -56,7 +56,7 @@ class Onenewspagevideo extends Searchengine
$next->resultCount = $this->resultCount; $next->resultCount = $this->resultCount;
$next->offset = $this->offset + $this->resultCount; $next->offset = $this->offset + $this->resultCount;
$next->getString .= "&o=" . $next->offset; $next->getString .= "&o=" . $next->offset;
$next->hash = md5($next->host . $next->getString . $next->port . $next->name); $next->hash = md5($next->engine->host . $next->getString . $next->engine->port . $next->name);
$this->next = $next; $this->next = $next;
} }
} }
...@@ -62,7 +62,7 @@ class Openclipart extends Searchengine ...@@ -62,7 +62,7 @@ class Openclipart extends Searchengine
} }
$next = new Openclipart($this->name, $this->engine, $metager); $next = new Openclipart($this->name, $this->engine, $metager);
$next->getString .= "&page=" . ($metager->getPage() + 1); $next->getString .= "&page=" . ($metager->getPage() + 1);
$next->hash = md5($next->host . $next->getString . $next->port . $next->name); $next->hash = md5($next->engine->host . $next->getString . $next->engine->port . $next->name);
$this->next = $next; $this->next = $next;
} catch (\Exception $e) { } catch (\Exception $e) {
Log::error("A problem occurred parsing results from $this->name:"); Log::error("A problem occurred parsing results from $this->name:");
......
...@@ -72,7 +72,7 @@ class Pixabay extends Searchengine ...@@ -72,7 +72,7 @@ class Pixabay extends Searchengine
} }
$next = new Pixabay($this->name, $this->engine, $metager); $next = new Pixabay($this->name, $this->engine, $metager);
$next->getString .= "&page=" . $page; $next->getString .= "&page=" . $page;
$next->hash = md5($next->host . $next->getString . $next->port . $next->name); $next->hash = md5($next->engine->host . $next->getString . $next->engine->port . $next->name);
$this->next = $next; $this->next = $next;
} catch (\Exception $e) { } catch (\Exception $e) {
Log::error("A problem occurred parsing results from $this->name:"); Log::error("A problem occurred parsing results from $this->name:");
......
...@@ -101,7 +101,7 @@ class Shopzilla extends Searchengine ...@@ -101,7 +101,7 @@ class Shopzilla extends Searchengine
$next->getString .= "&start=" . ($current + 10); $next->getString .= "&start=" . ($current + 10);
} }
$next->hash = md5($next->host . $next->getString . $next->port . $next->name); $next->hash = md5($next->engine->host . $next->getString . $next->engine->port . $next->name);
$this->next = $next; $this->next = $next;
} }
} }
...@@ -77,7 +77,7 @@ class Yandex extends Searchengine ...@@ -77,7 +77,7 @@ class Yandex extends Searchengine
} }
$next = new Yandex($this->name, $this->engine, $metager); $next = new Yandex($this->name, $this->engine, $metager);
$next->getString .= "&page=" . ($metager->getPage() + 1); $next->getString .= "&page=" . ($metager->getPage() + 1);
$next->hash = md5($next->host . $next->getString . $next->port . $next->name); $next->hash = md5($next->engine->host . $next->getString . $next->engine->port . $next->name);
} catch (\Exception $e) { } catch (\Exception $e) {
Log::error("A problem occurred parsing results from $this->name:\n" . $e->getMessage() . "\n" . $result); Log::error("A problem occurred parsing results from $this->name:\n" . $e->getMessage() . "\n" . $result);
return; return;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment