mirror of
https://github.com/PrivateBin/PrivateBin.git
synced 2025-12-11 06:26:20 -05:00
turned bootstrap template variants into logic
This commit is contained in:
parent
87fad1fb77
commit
67f6c4eb61
9 changed files with 25 additions and 21 deletions
|
|
@ -52,7 +52,8 @@ class View
|
|||
*/
|
||||
public function draw($template)
|
||||
{
|
||||
$path = PATH . 'tpl' . DIRECTORY_SEPARATOR . $template . '.php';
|
||||
$file = substr($template, 0, 9) === 'bootstrap' ? 'bootstrap' : $template;
|
||||
$path = PATH . 'tpl' . DIRECTORY_SEPARATOR . $file . '.php';
|
||||
if (!file_exists($path)) {
|
||||
throw new Exception('Template ' . $template . ' not found!', 80);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue