<?php include_once "../gfx3/lib.php"; $main = new EMain(); $temp = new EStructure(); $temp->code(); echo "<p style=\"color:green;\">Working!</p>"; $temp->insert("corelibs"); $temp->code(); $db = new EDatabase(); if ($db->status() == 0) { echo "<p style=\"color:green;\">Working!</p>"; } elseif ($db->status() == 1) { echo "<p style=\"color:red;\">No database found!</p>"; } else { echo "<p style=\"color:red;\">Connection refused!</p>"; } $temp->insert("database"); $temp->code(); echo "<p style=\"color:green;\">Working!</p>"; $temp->insert("templates");
$page = EHeaderDataParser::db_get("page"); $user = EHeaderDataParser::db_get("user"); if (!$from) { $from = "new"; } if (!$label) { $label = ""; } if (!$page) { $page = 1; } if (!$user) { $user = ""; } $client = new OCSClient(); $games = $client->get("v1/content/data?search={$label}&page={$page}&pagesize=50&sortmode={$from}&user={$user}"); EStructure::code(); if (isset($games["ocs"]["data"]["content"])) { if (isset($games["ocs"]["data"]["content"]["id"])) { $game = $games["ocs"]["data"]["content"]; echo "\n\t\t\t\t<div class=\"span6\">\n\t\t\t\t<div class=\"row\">\n\t\t\t\t <div class=\"span2\"><img src=\"" . $game["preview1"] . "\"></div>\n\t\t\t\t <div class=\"span4\"><h3><a href=\"/game.php/id/" . stripslashes($game["id"]) . "/title/" . ERewriter::prettify(stripslashes($game["name"])) . "\">" . stripslashes($game["name"]) . "</a></h3>\n\t\t\t\t <div class=\"static-rating\" id=\"" . $game["score"] . "_" . $game["id"] . "\"></div>\n\t\t\t\t <p>" . stripslashes($game["summary"]) . "</p>\n\t\t\t\t from <a data-toggle=\"modal\" href=\"#viewSelfProfileModal\" class=\"modalButton\" target=\"/viewProfileModal.php?login="******"personid"] . "\">" . $game["personid"] . "</a>\n\t\t\t\t </div>\n\t\t\t\t </div>\n\t\t\t\t <hr>\n\t\t\t\t </div>"; } else { foreach ($games["ocs"]["data"]["content"] as $game) { echo "\n\t\t\t\t<div class=\"span6\">\n\t\t\t\t<div class=\"row\">\n\t\t\t\t <div class=\"span2\"><img src=\"" . $game["preview1"] . "\"></div>\n\t\t\t\t <div class=\"span4\"><h3><a href=\"/game.php/id/" . stripslashes($game["id"]) . "/title/" . ERewriter::prettify(stripslashes($game["name"])) . "\">" . stripslashes($game["name"]) . "</a></h3>\n\t\t\t\t <div class=\"static-rating\" id=\"" . $game["score"] . "_" . $game["id"] . "\"></div>\n\t\t\t\t <p>" . stripslashes($game["summary"]) . "</p>\n\t\t\t\t from <a data-toggle=\"modal\" href=\"#viewSelfProfileModal\" class=\"modalButton\" target=\"/viewProfileModal.php?login="******"personid"] . "\">" . $game["personid"] . "</a>\n\t\t\t\t </div>\n\t\t\t\t </div>\n\t\t\t\t <hr>\n\t\t\t\t </div>"; } } } else { echo "Nothing found :("; } EStructure::insert("game_list"); EStructure::unload();