public static function __callStatic($method, $options) { $content = $options[0]; $tag = $options[1]; // get include information $nodes = $content->XPath("//include"); // include all page informations if (count($nodes)) { foreach ($nodes as $node) { $page = OLIVPage::_load((string) $node); olivxml_insert($content, $page->content); } } return $content; }
public function load($pageName = "") { $templateName = ""; $xml = OLIVPage::_load($pageName); if ($xml) { $this->structure = $xml->content; // look for template node $nodes = $this->structure->XPath("//template"); if ($nodes) { $templateName = (string) $nodes[0]; } if (!$templateName) { $templateName = "default"; } // store template name $this->template = $templateName; } }