This commit is contained in:
lopar
2018-03-01 16:51:01 +02:00
parent a8ff0a54f0
commit 5abf451314
3 changed files with 102 additions and 76 deletions

22
classes/nick.php Normal file
View File

@@ -0,0 +1,22 @@
<?php
/**
* Copyright (c) 2018.
* Author: Igor Barkov <lopar.4ever@gmail.com>
* Project name: Battles-Game
*/
class nick
{
private $user;
function __construct($id)
{
$this->user = db::c()->query('SELECT * FROM `users` WHERE `id` = ?i', $id)->fetch_assoc();
}
public function get()
{
return $this->user['login'];
}
}