function print_head($_header = NULL) { trace('Enter'); /* Plugin hook: on_header_print_before * Called before the HTML header is sent. * Args: $html: A reference to the HTML header. */ $this->eventbus->emit('on_header_print_before', $this->api); if ($_header) { echo $_header; } elseif (!headers_sent()) { header('Content-Type: text/html; charset=utf-8'); header('Pragma: no-cache'); header('Cache-control: no-cache'); trace('rendering header'); include 'controllers/header_controller.class.php'; $header = new HeaderController($this->api); $header->show($this->get_title()); trace('rendered header'); } trace('printed header'); /* Plugin hook: on_header_print_after * Called after the HTML header was sent. * Args: none */ $this->eventbus->emit('on_header_print_after', $this->api); trace('Leave'); }
<?php include "classes/controller/IController.php"; include "classes/controller/NavigationController.php"; include "classes/controller/HeaderController.php"; include "classes/controller/BodyController.php"; include "classes/view/View.php"; include "classes/model/Artist.php"; include "classes/model/Category.php"; include "classes/model/Museum.php"; include "classes/model/Owner.php"; include "classes/model/Picture.php"; include "classes/model/SearchData.php"; include "classes/model/DisplayPicture.php"; include "classes/model/ComparisonPicture.php"; include "includes/DbManager.php"; session_start(); $request = array_merge($_GET, $_POST, $_FILES); $headerController = new HeaderController($request); $navigationController = new NavigationController($request); $bodyController = new BodyController($request); echo $headerController->display(); echo $navigationController->display(); echo $bodyController->display();
<?php session_start(); require_once __DIR__ . "/../controllers/HeaderController.php"; $header = new HeaderController(); if ($header->checkLoggedIn()) { $user_data = $header->getSessionData(); } else { $user_data = ''; } ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title><?php echo $header->titleMaker(); ?> </title> <!-- Load bootstrap css--> <link rel="stylesheet" href="<?php echo ROOT_URL; ?> includes/template/bootstrap/css/bootstrap.min.css"> <!-- Load font--> <link href='https://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css'> <!-- Load main stylesheet--> <link href="<?php echo ROOT_URL; ?> includes/template/stylesheet/stylesheet_main.css" rel="stylesheet" type="text/css" />