Pimcore\Model\Site\Dao::getByRootId PHP Method

getByRootId() public method

public getByRootId ( $id )
$id
    public function getByRootId($id)
    {
        $data = $this->db->fetchRow("SELECT * FROM sites WHERE rootId = ?", $id);
        if (!$data["id"]) {
            throw new \Exception("there is no site for the requested rootId");
        }
        $this->assignVariablesToModel($data);
    }