예제 #1
0
 public function getPageTitle()
 {
     if (!empty($this->pageTitle)) {
         return String::clean($this->pageTitle) . ' | ' . $this->siteTitle;
     } else {
         return $this->settings->siteTitle;
     }
 }
예제 #2
0
 /**
  * Get the content, from the template, replacing any tags with function calls
  * 
  * @return string
  */
 public function getContent()
 {
     $rawContent = file_get_contents($this->viewPath . $this->template);
     $tags = array('{name}' => String::clean($this->name), '{label}' => String::clean($this->label), '{value}' => String::clean($this->value), '{properties}' => $this->displayProperties(), '{errors}' => $this->getErrors(), '{options}' => $this->getOptions());
     $content = str_replace(array_keys($tags), array_values($tags), $rawContent);
     return $content;
 }