updated defaults from examples

This commit is contained in:
2024-09-27 12:58:19 -07:00
parent 7cd3071905
commit 0d4b62ffb9
10 changed files with 37 additions and 8 deletions

11
defaults/App/config.php Normal file
View File

@@ -0,0 +1,11 @@
<?php
$config = [
'database' => [
'host' => '',
'name' => '',
'user' => '',
'pass' => '',
'port' => 3306
],
'base_url' => 'http://localhost:8000'
];

View File

@@ -0,0 +1,15 @@
<?php
// Define our status code and message
$status_code = 404;
$status_message = 'The requested resource could not be found.';
// Set the HTTP response code and message
http_response_code($status_code);
header("Content-Type: text/html");
?>
<h1>Error 404 Resource Not found</h1>
<p><?php echo $status_message; ?></p>
<p style="font-size:10px; margin-top:60px">Novaconium Default 404 page.</p>

View File

@@ -0,0 +1,2 @@
<?php
echo $twig->render('index.html.twig');

9
defaults/App/routes.php Normal file
View File

@@ -0,0 +1,9 @@
<?php
$routes = [
'/about' => [
'get' => 'about'
],
'/' => [
'get' => 'index'
]
];

View File

@@ -0,0 +1 @@
{# Overrides go here #}

View File

@@ -0,0 +1,7 @@
{% extends '@novaconium/master.html.twig' %}
{% block content %}
<h1>This is twig</h1>
<p>Content Here</p>
{% endblock %}

View File

@@ -0,0 +1,4 @@
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?_uri=$1 [QSA,L]

View File

@@ -0,0 +1,6 @@
<?php
// error_reporting(E_ALL);
// ini_set('display_errors', 1);
define('BASEPATH', dirname(__DIR__, 1));
require_once(BASEPATH . '/vendor/4lt/novaconium/src/novaconium.php');
?>