mirror of
https://github.com/Aviortheking/DeltaCMS.git
synced 2025-07-30 21:40:45 +00:00
too manu changes (will list by files)
.gitignore ignores some launch files changelog.md, readme.md added end file line public.php moved started the work on it router.php added require to functions & moved the function in the file set an ini value to show errors defied some constants moved the public page management to public/public.php exampleModule -> headGenerator.php started working on module management *.json reworked files function.php added this file to manages cores functions website.php the Website Object for theme & modules page.php created a test theme
This commit is contained in:
40
public/public.php
Normal file
40
public/public.php
Normal file
@ -0,0 +1,40 @@
|
||||
<?php
|
||||
/**
|
||||
* The process to load a public page (located in /pages)
|
||||
*/
|
||||
|
||||
$isCacheActive = SETTINGS["cache"];
|
||||
|
||||
$webPage = "<html><head><placeholder type=\"head\"/></head><body>" . getWebPage($isCacheActive) . "</body>";
|
||||
|
||||
//load .css & .js
|
||||
|
||||
$doc = new DOMDocument();
|
||||
libxml_use_internal_errors(true);
|
||||
$doc->loadHTML($webPage);
|
||||
libxml_clear_errors();
|
||||
|
||||
//handle modules here
|
||||
|
||||
echo $doc->saveHTML();
|
||||
|
||||
/*
|
||||
|
||||
if cache is active
|
||||
if active is active load cache (scripts.js styles.css)
|
||||
load templates.json
|
||||
if template has cache for webpage and cache exist
|
||||
load the file
|
||||
else
|
||||
launch generateWebPage()
|
||||
|
||||
load theme css & js
|
||||
|
||||
|
||||
if modules are in the page
|
||||
load the modules
|
||||
|
||||
|
||||
|
||||
*/
|
||||
?>
|
Reference in New Issue
Block a user