default theme

This commit is contained in:
2025-01-16 16:14:43 +03:00
parent c228a70468
commit dac4db96af
23 changed files with 11658 additions and 348 deletions

View File

@ -10,14 +10,19 @@ class MainController extends Controller
protected function init(): void
{
parent::init();
$this->cgView->viewPath = APP_DIR . "/themes/default/views/main/";
$this->cgView->viewPath = KERNEL_DIR . "/themes/default/views/main/";
$this->cgView->layout = "main.php";
$this->cgView->layoutPath = APP_DIR . "/themes/default/views/layout/";
$this->cgView->addVarToLayout("resources", "/resources/default");
$this->cgView->layoutPath = KERNEL_DIR . "/themes/default/views/layout/";
$this->cgView->addVarToLayout("resources", "/resources/themes/default");
}
public function actionIndex(): void
{
$this->cgView->render("index.php");
}
public function actionAbout(): void
{
$this->cgView->render("about.php");
}
}