diff --git a/examples/App/controllers/404.php b/examples/App/controllers/404.php new file mode 100644 index 0000000..101d995 --- /dev/null +++ b/examples/App/controllers/404.php @@ -0,0 +1 @@ +

This is 404

\ No newline at end of file diff --git a/examples/App/controllers/index.php b/examples/App/controllers/index.php new file mode 100644 index 0000000..d0182fa --- /dev/null +++ b/examples/App/controllers/index.php @@ -0,0 +1,2 @@ +render('index.html.twig'); \ No newline at end of file diff --git a/examples/App/public/.htaccess b/examples/App/public/.htaccess new file mode 100644 index 0000000..f6351db --- /dev/null +++ b/examples/App/public/.htaccess @@ -0,0 +1,6 @@ +RewriteEngine On + +RewriteCond %{REQUEST_FILENAME} !-f +RewriteCond %{REQUEST_FILENAME} !-d + +RewriteRule ^(.*)$ index.php?_uri=$1 [QSA,L] \ No newline at end of file diff --git a/examples/App/public/index.php b/examples/App/public/index.php new file mode 100644 index 0000000..decf738 --- /dev/null +++ b/examples/App/public/index.php @@ -0,0 +1,6 @@ + \ No newline at end of file diff --git a/examples/App/routes.php b/examples/App/routes.php new file mode 100644 index 0000000..20dea35 --- /dev/null +++ b/examples/App/routes.php @@ -0,0 +1,9 @@ + [ + 'file' => 'about' + ], + '/' => [ + 'file' => 'index' + ] +]; \ No newline at end of file diff --git a/examples/App/views/index.html.twig b/examples/App/views/index.html.twig new file mode 100644 index 0000000..a38042f --- /dev/null +++ b/examples/App/views/index.html.twig @@ -0,0 +1,7 @@ +{% extends '@nytwig/master.html.twig' %} + +{% block content %} +

This is twig

+

Content Here

+{% endblock %} +