/** * * @param string $name * @return string */ protected function get_template_path($name) { $path = nc_search::get_module_path() . "/views/{$name}.php"; if (!preg_match("/^\\w+\$/", $name) || !file_exists($path)) { $this->halt_param('view'); } return $path; }