Beispiel #1
0
 private function AddNameField()
 {
     $name = 'Name';
     $this->AddField(Input::Text($name, $this->layout->GetName()));
     $this->SetRequired($name);
     $this->AddValidator($name, DatabaseCount::UniqueField($this->layout, $name));
 }
Beispiel #2
0
 /**
  * The template file for a page layout
  * @param Layout $layout The page layout
  * @return string Returns the layout template path
  */
 static function LayoutTemplate(Layout $layout)
 {
     $folder = Path::Combine(PHINE_PATH, 'LayoutTemplates');
     $file = Path::Combine($folder, $layout->GetName());
     return Path::AddExtension($file, 'phtml');
 }