public static function getByRole($role) { global $db; $roleSQL = "SELECT * FROM roles WHERE role LIKE '%?%'"; $values = array($role); $role = $db->qwv($roleSQL, $values); return Role::wrap($role); }
public static function getByID($id) { global $db; $roleSQL = "SELECT * FROM roles WHERE roleid=?"; $values = array($id); $role = $db->qwv($roleSQL, $values); return Role::wrap($role); }
public static function getByName($name){ $base = new Base(); $roleSQL = "SELECT * FROM roles WHERE name LIKE '%?%'"; $values = array($name); $role = $base->db->qwv($roleSQL, $values); return Role::wrap($role); }