Changed variables.

This commit is contained in:
2026-07-04 07:43:33 -07:00
parent 7ee47a0b1e
commit 4484f88d8d
21 changed files with 197 additions and 197 deletions
@@ -1,5 +1,5 @@
<?php
$data = array_merge($data, [
$ctx->withData([
'title' => 'Welcome to Novaconium Index Page',
'pageclass' => 'novaconium'
]);
+10 -11
View File
@@ -1,7 +1,7 @@
<?php
$slug = $router->parameters['slug'];
$slug = $ctx->router->parameters['slug'];
$query=<<<EOSQL
SELECT
SELECT
id,
title,
heading,
@@ -11,23 +11,22 @@ $query=<<<EOSQL
body,
created,
updated
FROM pages
WHERE slug = '$slug'
FROM pages
WHERE slug = ?
EOSQL;
//$db->debugGetRow($query);
$data = $db->getRow($query);
if(!$data) {
$page = $ctx->db->getRow($query, [$slug]);
if(!$page) {
http_response_code('404');
header("Content-Type: text/html");
view('404');
exit;
}
$data = array_merge($data, [
$ctx->withData(array_merge($page, [
'menuActive' => 'blog',
'pageid' => 'page',
'permissionsGroup' => $session->get('group')
]);
'permissionsGroup' => $ctx->session->get('group')
]));
view('page', $data);
view('page', $ctx->data);
@@ -6,7 +6,7 @@ header('Content-Type: text/plain; charset=UTF-8');
header('Cache-Control: public, max-age=604800');
// Use $config['base_url'] as-is
$baseUrl = $config['base_url'];
$baseUrl = $ctx->config['base_url'];
echo <<<TXT
# robots.txt for sites powered by Novaconium framework