Rewrites/fixes for handling config entries in SQLs
[mailer.git] / inc / header.php
index 58ba602bd7c6755206155cb56d793d218a0d4a73..0313f88583d39f2c2deefa01e9f7bd96095b6b77 100644 (file)
@@ -20,6 +20,7 @@
  * svn:keywords Date Revision" (autoprobset!) at least!!!!!!            *
  * -------------------------------------------------------------------- *
  * Copyright (c) 2003 - 2009 by Roland Haeder                           *
+ * Copyright (c) 2009, 2010 by Mailer Developer Team                    *
  * For more information visit: http://www.mxchange.org                  *
  *                                                                      *
  * This program is free software; you can redistribute it and/or modify *
@@ -43,37 +44,21 @@ if (!defined('__SECURITY')) {
        die();
 } // END - if
 
+// Init header
+$GLOBALS['page_header'] = '';
+
 // Is the header already sent?
 if (($GLOBALS['header_sent'] != 1) && ($GLOBALS['header_sent'] != 2)) {
+       // Set default HTTP status to "200 OK"
+       setHttpStatus('200 OK');
+
        // If not in CSS mode generate the header
        if (getOutputMode() != 1) {
-               // Determine the page title
-               $content['header_title'] = determinePageTitle();
-
-               // Output page header code
-               loadTemplate('page_header', false, $content);
-
-               // Include meta data in 'guest' module
-               if (getModule() == 'index') {
-                       // Load meta data template
-                       loadTemplate('metadata');
-
-                       // Add meta description to header
-                       if ((isInstalled()) && (isAdminRegistered()) && (SQL_IS_LINK_UP())) {
-                               // Add meta description not in admin and login module and when the script is installed
-                               generateMetaDescriptionCode(getModule(), getWhat());
-                       } // END - if
-               } // END - if
-
-               // Include more header data here
-               loadTemplate('header');
-
-               // Include stylesheet
-               loadIncludeOnce('inc/stylesheet.php');
+               // Prepare the header for HTML output
+               loadHtmlHeader();
        } // END - if
 
        // Closing HEAD tag
-       if (getOutputMode() != 1) outputHtml('</head>');
        if ($GLOBALS['header_sent'] == '0') $GLOBALS['header_sent'] = 1;
 } // END - if