$content) { $template = str_replace('%' . $name . '%', $content, $template); } } return $template; } /** * @param string $path * @return bool */ public function canRender($path) { return strpos($path, '.htm') && file_exists($path); } }