"Access not authorized"); } $database = SqliteDatabase::getSingleton(); $projects = $database->queryArray("SELECT rowid AS project_id, * FROM projects WHERE project_id IN (SELECT project_id FROM account_projects WHERE account_id = ".$_SESSION['client_id'].");"); return array("projects" => $projects); } private function isLoggedIn() { return isset($_SESSION['authorized']) && $_SESSION['authorized']; } }