Class User{
public $id;
public $username;
public $password;
public $email;
public $steam;
public $donator;
public $active;
public function __construct($username,
You can store objects in $_SESSION. PHP will serialize them for you. Just make sure the class is defined before calling session_start, or that it can be autoloaded. The reason the value stored in the session has type "__PHP_Incomplete_Class_Name" is that the User class wasn't defined when the object was unserialized during session loading (as explained in the PHP manual page on object serialization).
Resources can't be serialized. If you ever store an object that uses resources, implement __sleep and __wakeup to customize the serialization. PHP's serialization should be able handle all other types, even if they contain circular references.