X-Git-Url: https://git.mxchange.org/?p=shipsimu.git;a=blobdiff_plain;f=inc%2Fclasses%2Fmain%2Fcommands%2Flocal%2Fclass_LocalHomeCommand.php;h=02f0928f844b7e9e7376d59e6437b0330337ceda;hp=c670cb1de84af66c2ac21f3849b348cc5712ed0d;hb=1798410d1248aa1fb0dd0b08fec1948c36aa8a26;hpb=96ef029e838836b7116290cdcb541ace4e183e35 diff --git a/inc/classes/main/commands/local/class_LocalHomeCommand.php b/inc/classes/main/commands/local/class_LocalHomeCommand.php index c670cb1..02f0928 100644 --- a/inc/classes/main/commands/local/class_LocalHomeCommand.php +++ b/inc/classes/main/commands/local/class_LocalHomeCommand.php @@ -78,11 +78,23 @@ class LocalHomeCommand extends BaseCommand implements Commandable { // Load the master template $masterTemplate = $appInstance->getMasterTemplate(); + // Load the home template + $templateInstance->loadWebTemplate("home"); + + // Assign the home template with the master template as a content ... ;) + $templateInstance->assignTemplateWithVariable("home", "content"); + // Load the master template $templateInstance->loadCodeTemplate($masterTemplate); - // Load the home template - $templateInstance->loadWebTemplate("home"); + // Compile it... + $templateInstance->compileTemplate(); + + // ... and all variables. This should be merged together in a pattern + // to make things easier. A cache mechanism should be added between + // these two calls to cache compiled templates. + $templateInstance->compileVariables(); + die("
".print_r($templateInstance, true)."
"); } }