title = $title; return $this; } public function getTitle() { return $this->title; } protected function getHead() { return ''; } protected function getBody() { return $this->renderChildren(); } protected function getTail() { return ''; } public function render() { $title = $this->getTitle(); $head = $this->getHead(); $body = $this->getBody(); $tail = $this->getTail(); return << {$title} {$head} {$body} {$tail} EOHTML; } }