rendered paste body private function getData() { $query = "SELECT board.id, board.section_id, board.name, board.dir, board.description, board.filesize, board.banner, board.threads_page, board.threads_board, board.forced_anonymous, board.comment_length, board.thread_length, section.id AS section_id, section.name AS section_name, ( SELECT COUNT(*) FROM ".Config::get('post_relation')." WHERE board_id = ".$this->id." ) AS post_amount FROM ".Config::get('board_relation')." AS board, ".Config::get('section_relation')." AS section WHERE board.id = ".$this->id." AND board.section_id = section.id LIMIT 0 , ".Config::get('threads_pr_board'); die($query); if ($result = Database::singleton()->query($query)) { while ($row = $result->fetch_assoc()) { foreach ($row as $key => $value) { $this->$key = $value; } } $this->data = true; } else { die("Error:".Database::singleton()->error.'<hr />'.$query); } }