Archived
1
0
Fork 0

more parsing

This commit is contained in:
Alexander Yakovlev 2017-10-07 19:08:42 +07:00
parent bfb5143d1f
commit 0fc8299671

View file

@ -26,17 +26,16 @@ class Steam extends Source {
foreach ($games as $gameLink) {
$url = $gameLink->getAttribute('href');
$text = $this->get_text($url);
$game = new Game;
/*
$game->title = $gameData->title;
$game->author = $gameData->developer->display_name;
$game->date = $gameData->published_on;
$game->description = $descData->payload->metaDescription;
$game->url = 'https://gamejolt.com/games/'.$gameData->slug.'/'.$gameData->id;
if ($game->date < $this->period) {
try {
$this->dom->loadStr($text, []);
} catch (Exception $e) {
continue;
}
*/
unset($text);
$game = new Game;
$game->title = $this->dom->find('.apphub_AppName')->innerHtml;
$game->description = $this->dom->find('.game_description_snippet')->innerHtml;
$game->url = $url;
$this->output .= $game->print();
}
}