Example #1
0
 public function startup()
 {
     parent::startup();
     $this->tree[0] = $this->translator->translate('page.noParent');
     $this->modules = array('' => $this->translator->translate('page.noModule'));
     if (isset($this->context->parameters['page']) && !is_null($this->context->parameters['page']['modules'])) {
         foreach ($this->context->parameters['page']['modules'] as $module) {
             $this->modules[\Nette\Utils\Strings::webalize(str_replace('page.', '', $module))] = $this->translator->translate($module);
         }
     }
 }
Example #2
0
 public function startup()
 {
     parent::startup();
     $this->template->setFile(dirname(__FILE__) . '/../templates/Setting/default.latte');
 }
Example #3
0
 public function startup()
 {
     parent::startup();
     //test emailu
     if (isset($_GET['mailTest'])) {
         $message = new \App\Email\Mail($this);
         $message->setSubject('Testovací email');
         $message->setHtmlBody('<h1>Testovací email</h1><p>ěščřžýáíé</p>');
         try {
             $message->addTo('vsek@seznam.cz');
             $message->addTo('stodulka@webnolimit.cz');
             $this->mailer->send($message);
             echo 'ODESLANO';
             exit;
         } catch (\Nette\Mail\SmtpException $e) {
             echo 'NEODESLANO';
             exit;
         }
     }
 }
Example #4
0
 public function startup()
 {
     parent::startup();
     $this->tree[0] = $this->translator->translate('category.noParent');
 }