Пример #1
0
 function fill($file_name, $data)
 {
     $uri = "app{$this->module}/v/" . (preg_match('/\\./', $file_name) ? _php($file_name) : $this->controller . "." . _php($file_name));
     if (is_array($data)) {
         extract($data);
     }
     if (file_exists($uri)) {
         include $uri;
     } else {
         $_SESSION['flash'] = "2#O arquivo {$uri} ainda não foi criado";
     }
 }
Пример #2
0
function my_own_helpers($helper = "moh")
{
    $file = "app/personal/" . _php($helper);
    if (file_exists($file)) {
        include $file;
    }
}