Example #1
0
 /**
  * Add block xml before </body> to add the site manager admin panel
  */
 public function addAdminPanel()
 {
     if ($this->user->isAdmin()) {
         $this->template->addFootData($this->blockParser->parse('<block type="module" permission="user" editable="false"><class>\\Fraym\\SiteManager\\SiteManagerController</class><method>adminPanelInit</method><checkRoute>checkRoute</checkRoute></block>'));
     }
 }
Example #2
0
 /**
  * @param $xml
  * @return string
  */
 public function execBlockOfTypeJavascript($xml)
 {
     $this->template->addFootData('<script type="text/javascript">' . (string) $xml . '</script>');
     return '';
 }