diff --git a/src/controller/user/User.php b/src/controller/user/User.php index aed9381..a74e031 100644 --- a/src/controller/user/User.php +++ b/src/controller/user/User.php @@ -1,21 +1,27 @@ render('user/login.html.twig'); + } public function register(): void - {} + { + $this->render('user/register.html.twig'); + } } diff --git a/src/router/Router.php b/src/router/Router.php index 6ea62f8..dcad083 100644 --- a/src/router/Router.php +++ b/src/router/Router.php @@ -43,7 +43,7 @@ final class Router implements RouterInterface if ($this->get) { switch ($this->get[self::CONTROLLER]) { case 'user': - $userController = new User(); + $userController = new User($this->core); switch ($this->get[self::ACTION]) { case 'login': return $userController->login(); diff --git a/src/template/user/login.html.php b/src/template/user/login.html.php deleted file mode 100644 index b3d9bbc..0000000 --- a/src/template/user/login.html.php +++ /dev/null @@ -1 +0,0 @@ -Login +
+
+ + +
+
+ + +
+ +
+{% endblock %} diff --git a/src/template/user/register.html.twig b/src/template/user/register.html.twig new file mode 100644 index 0000000..b1716e4 --- /dev/null +++ b/src/template/user/register.html.twig @@ -0,0 +1,20 @@ +{% extends "frames/default.html.twig" %} +{% block title %}register{% endblock %} +{% block content %} +

Register

+
+
+ + +
+
+ + +
+
+ + +
+ +
+{% endblock %} diff --git a/src/template/user/registration.html.php b/src/template/user/registration.html.php deleted file mode 100644 index b3d9bbc..0000000 --- a/src/template/user/registration.html.php +++ /dev/null @@ -1 +0,0 @@ -