public function load() { if ($this->id != 0) { $sql = "SELECT *\n FROM `{$this->table_name}`\n WHERE `{$this->id_field}`={$this->id};"; if (!($this->data = $this->DbConnection->getOneRow($sql))) { return false; } $this->loaded = true; return true; } return false; }