getRequest(); $templateMgr = TemplateManager::getManager($request); // Add the filter's directory as additional template dir so that // templates can include sub-templates in the same folder. array_unshift($templateMgr->template_dir, $this->getBasePath()); // Give sub-filters a chance to add their variables // to the template. $this->addTemplateVars($templateMgr, $input, $request, $locale); // Use a base path hash as compile id to make sure that we don't // get namespace problems if several filters use the same // template names. $previousCompileId = $templateMgr->compile_id; $templateMgr->compile_id = md5($this->getBasePath()); // Let the template engine render the citation. $output = $templateMgr->fetch($this->getTemplateName()); // Remove the additional template dir array_shift($templateMgr->template_dir); // Restore the compile id. $templateMgr->compile_id = $previousCompileId; return $output; } } ?>