]> git.mxchange.org Git - mailer.git/blobdiff - inc/header.php
Extension 'yoomedia' now alpha status, some rewrites
[mailer.git] / inc / header.php
index 1031590a81c4746f0a56a7933c295454fb0541d8..fe18f73c4e5add995bac2de8534de4b4f3f6009f 100644 (file)
@@ -80,7 +80,7 @@ if (($header != "1") && ($header != "2")) {
 
                                // Remember title in constant for the template
                                define('__PAGE_TITLE', html_entity_decode($TITLE));
-                       } elseif ((!defined('mxchange_installed')) || (!defined('admin_registered'))) {
+                       } elseif ((!isBooleanConstantAndTrue('mxchange_installed')) || (!isBooleanConstantAndTrue('admin_registered'))) {
                                // Load language file because it was missing in installation finalizer step... *sigh*
                                require_once(sprintf("%sinc/language/install_%s.php",
                                        PATH,
@@ -104,13 +104,15 @@ if (($header != "1") && ($header != "2")) {
                // Output page header code
                LOAD_TEMPLATE("page_header");
 
-               // Include meta data here
-               LOAD_TEMPLATE("metadata");
+               // Include meta data in "guest" module
+               if ($GLOBALS['module'] == "index") {
+                       LOAD_TEMPLATE("metadata");
 
-               // Add meta description to header
-               if ((isBooleanConstantAndTrue('mxchange_installed')) && (isBooleanConstantAndTrue('admin_registered')) && ($GLOBALS['module'] != "admin") && ($GLOBALS['module'] != "login") && (isset($db)) && (isset($link))) {
-                       // Add meta description not in admin and login module and when the script is installed
-                       META_DESCRIPTION($GLOBALS['module'], $GLOBALS['what']);
+                       // Add meta description to header
+                       if ((isBooleanConstantAndTrue('mxchange_installed')) && (isBooleanConstantAndTrue('admin_registered')) && (isset($db)) && (is_resource($link))) {
+                               // Add meta description not in admin and login module and when the script is installed
+                               META_DESCRIPTION($GLOBALS['module'], $GLOBALS['what']);
+                       } // END - if
                } // END - if
 
                // Include more header data here