20 lines
432 B
PHP

<?php
$data = array_merge($data, [
'title' => 'Novaconium Pages',
'pageclass' => 'novaconium'
]);
if ( empty($session->get('username'))) {
$redirect->url('/novaconium/login');
$messages->error('You are not loggedin');
makeitso();
}
// Get the pages
$query = "SELECT id, title, created, updated, draft FROM pages";
$matched = $db->getRows($query);
$data['pages'] = $matched;
view('@novacore/pages', $data);