public function getDefaultRobots() { $oldPath = craft()->path->getTemplatesPath(); $newPath = craft()->path->getPluginsPath() . 'seomatic/templates'; craft()->path->setTemplatesPath($newPath); /* -- Return the robots.txt default template */ $templateName = '_robotsDefault'; $loader = new TemplateLoader(); $template = $loader->getSource($templateName); craft()->path->setTemplatesPath($oldPath); return $template; }