Include common HTML headers
static public includeHeader ( $title = '' ) : nothing | ||
$title | title used for the page (default '') | |
return | nothing |
https://forge.indepnet.net/projects/mreporting ------------------------------------------------------------------------- LICENSE This file is part of mreporting. mreporting is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. mreporting is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with mreporting. If not, see <http://www.gnu.org/licenses/>. -------------------------------------------------------------------------- */ include "../../../inc/includes.php"; header("Content-Type: text/html; charset=UTF-8"); Html::header_nocache(); Html::includeHeader(""); echo "<div class='debug_content'>"; $common = new PluginMreportingCommon(); $common->debugGraph(); echo "</div></div></div>"; echo "</body></html>";
/** * Show API header * in debug, it add body and some libs (essentialy to colorise markdown) * otherwise, it change only Content-Type of the page * * @param $html (default false) * @param $title (default '') **/ protected function header($html = false, $title = "") { // Send UTF8 Headers $content_type = "application/json"; if ($html) { $content_type = "text/html"; } header("Content-Type: {$content_type}; charset=UTF-8"); // Send extra expires header Html::header_nocache(); if ($html) { if (empty($title)) { $title = $this->getTypeName(); } Html::includeHeader($title); // Body with configured stuff echo "<body>"; echo "<div id='page'>"; } }