diff --git a/jensmemes.php b/jensmemes.php index 6c44b02..cf6cebb 100644 --- a/jensmemes.php +++ b/jensmemes.php @@ -110,7 +110,8 @@ if ($method == "GET") { while ($row = mysqli_fetch_array($res_users, MYSQLI_ASSOC)) { $user = new stdClass(); $user->name = $row["name"]; - $user->tokenhash = md5($row["token"]); + $user->tokenhash = $row["userdir"]; + $user->userdir = $row["userdir"]; $user->dayuploads = $row["uploadsLast24H"]; array_push($users, $user); } @@ -161,6 +162,7 @@ function checksql($res) { function memesArray($query) { global $jmcon; + global $jmurl; $memes = array(); $res_memes = mysqli_query($jmcon, $query); @@ -170,6 +172,7 @@ function memesArray($query) { $meme->id = $row["id"]; $path = $row["path"]; $path = str_replace(" ", "%20", $path); + $meme->link = $jmurl . $path; $meme->path = $path; $meme->category = $row["cat"]; $meme->user = $row["user"];