Even more fixes/improvements:
authorRoland Häder <roland@mxchange.org>
Wed, 23 Jun 2010 13:26:45 +0000 (13:26 +0000)
committerRoland Häder <roland@mxchange.org>
Wed, 23 Jun 2010 13:26:45 +0000 (13:26 +0000)
- Added filter pre_youhere_line. It will be executed directly before the
  div-block of the 'You are here' navigation
- Saved an else-block and br-tag in same function
- For that missing br-tag a CSS 'margin-bottom' needs to be added to
  you_are_here CSS class
- Fixed default value for an enum in ext-removeip in the configuration SQL query

inc/extensions/ext-removeip.php
inc/filter-functions.php
inc/libs/removeip_functions.php
inc/mysql-manager.php
theme/business/css/general.css
theme/default/css/general.css
theme/desert/css/general.css
theme/org/css/general.css

index cb4a2419890c6bfd476025ca5ec3eb405ac1b81e..c0985287df2810736b8d259a46b9a7287c66200f 100644 (file)
@@ -60,7 +60,7 @@ switch (getExtensionMode())
                addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_config` ADD `removeip_guest_show` ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_config` ADD `removeip_member_show` ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_config` ADD `removeip_sponsor_show` ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_config` ADD `removeip_guest_show` ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_config` ADD `removeip_member_show` ENUM('Y','N') NOT NULL DEFAULT 'Y'");
                addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_config` ADD `removeip_sponsor_show` ENUM('Y','N') NOT NULL DEFAULT 'Y'");
-               addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_config` ADD `anonymous_ip` ENUM('LOCAL','ZERO','RANDOM') NOT NULL DEFAULT '127.0.0.1'");
+               addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_config` ADD `anonymous_ip` ENUM('LOCAL','ZERO','RANDOM') NOT NULL DEFAULT 'LOCAL'");
                addAdminMenuSql('setup','config_removeip','Anonymit&auml;t/Privatsph&auml;hre','Stellen Sie hier ein, ob die IP-Nummer, User-Agent und/oder Referer-Adresse anonymisiert im gesamten Script verwendet werden soll.',15);
                break;
 
                addAdminMenuSql('setup','config_removeip','Anonymit&auml;t/Privatsph&auml;hre','Stellen Sie hier ein, ob die IP-Nummer, User-Agent und/oder Referer-Adresse anonymisiert im gesamten Script verwendet werden soll.',15);
                break;
 
@@ -92,7 +92,7 @@ switch (getExtensionMode())
                                // Update notes (these will be set as task text!)
                                setExtensionUpdateNotes("Filter hinzugef&uuml;gt und ist von <strong>sql_patches</strong> abh&auml;ngig.");
                                break;
                                // Update notes (these will be set as task text!)
                                setExtensionUpdateNotes("Filter hinzugef&uuml;gt und ist von <strong>sql_patches</strong> abh&auml;ngig.");
                                break;
-               }
+               } // END - switch
                break;
 
        case 'modify': // When the extension got modified
                break;
 
        case 'modify': // When the extension got modified
@@ -107,7 +107,7 @@ switch (getExtensionMode())
        default: // Unknown extension mode
                logDebugMessage(__FILE__, __LINE__, sprintf("Unknown extension mode %s in extension %s detected.", getExtensionMode(), getCurrentExtensionName()));
                break;
        default: // Unknown extension mode
                logDebugMessage(__FILE__, __LINE__, sprintf("Unknown extension mode %s in extension %s detected.", getExtensionMode(), getCurrentExtensionName()));
                break;
-}
+} // END - switch
 
 // [EOF]
 ?>
 
 // [EOF]
 ?>
index 7c0296dad20c472114c501418ec3e4fc5c97a0f1..9030f97ad393615785f358ff92760d512e6fe773 100644 (file)
@@ -122,7 +122,7 @@ ORDER BY
        registerFilter('post_page_header', 'FINISH_PAGE_HEADER');
        // ------------------- LAST FILTER FOR THIS CHAIN! ------------------------
 
        registerFilter('post_page_header', 'FINISH_PAGE_HEADER');
        // ------------------- LAST FILTER FOR THIS CHAIN! ------------------------
 
-       // Login failures handler
+       // 'You are here' navigation - post filter
        registerFilter('post_youhere_line', 'CALL_HANDLER_LOGIN_FAILTURES');
 
        // Filters for pre-extension-registration
        registerFilter('post_youhere_line', 'CALL_HANDLER_LOGIN_FAILTURES');
 
        // Filters for pre-extension-registration
index 112bef3ab03430e1c06a3727da295103802b0b58..ba03102accb0b72477d0060ef01b6ddf16140e39 100644 (file)
@@ -40,7 +40,7 @@
 // Some security stuff...
 if (!defined('__SECURITY')) {
        die();
 // Some security stuff...
 if (!defined('__SECURITY')) {
        die();
-}
+} // END - if
 
 // "Getter" for anonymous remote IP number
 function getAnonymousRemoteAddress ($remoteAddr) {
 
 // "Getter" for anonymous remote IP number
 function getAnonymousRemoteAddress ($remoteAddr) {
index e0f783715494dc0af63df3f176d6c82a936926f4..5c996cea14c0f6c20ee8cb74c222ae101d37505c 100644 (file)
@@ -302,6 +302,7 @@ function addMenuDescription ($accessLevel, $FQFN, $return = false) {
        $LINK_ADD = '';
        $OUT = '';
        $ADD = '';
        $LINK_ADD = '';
        $OUT = '';
        $ADD = '';
+       $prefix = '';
 
        // First we have to do some analysis...
        if (substr($file, 0, 7) == 'action-') {
 
        // First we have to do some analysis...
        if (substr($file, 0, 7) == 'action-') {
@@ -344,11 +345,19 @@ function addMenuDescription ($accessLevel, $FQFN, $return = false) {
 
        // Begin the navigation line
        if ((!isset($GLOBALS['nav_depth'])) && ($return === false)) {
 
        // Begin the navigation line
        if ((!isset($GLOBALS['nav_depth'])) && ($return === false)) {
+               // Init nav_depth
                $GLOBALS['nav_depth'] = '0';
                $GLOBALS['nav_depth'] = '0';
-               $prefix = '<div class="you_are_here">{--YOU_ARE_HERE--}&nbsp;<strong><a class="you_are_here" href="{%url=modules.php?module=' . getModule() . $LINK_ADD . '%}">Home</a></strong>';
-       } else {
-               if ($return === false) $GLOBALS['nav_depth']++;
-               $prefix = '';
+
+               // Run the pre-filter chain
+               $ret = runFilterChain('pre_youhere_line', array('access_level' => $accessLevel, 'type' => $type, 'content' => ''));
+
+               // Add pre-content
+               $prefix = $ret['content'];
+
+               $prefix .= '<div class="you_are_here">{--YOU_ARE_HERE--}&nbsp;<strong><a class="you_are_here" href="{%url=modules.php?module=' . getModule() . $LINK_ADD . '%}">Home</a></strong>';
+       } elseif ($return === false) {
+               // Count depth
+               $GLOBALS['nav_depth']++;
        }
 
        $prefix .= '&nbsp;-&gt;&nbsp;';
        }
 
        $prefix .= '&nbsp;-&gt;&nbsp;';
@@ -368,16 +377,16 @@ function addMenuDescription ($accessLevel, $FQFN, $return = false) {
                if (($type == 'what') || (($type == 'action') && ((!isWhatSet()) || (getWhat() == 'overview')))) {
                        //* DEBUG: */ print(__LINE__.'+'.$type."+<br />");
                        // Add closing div and br-tag
                if (($type == 'what') || (($type == 'action') && ((!isWhatSet()) || (getWhat() == 'overview')))) {
                        //* DEBUG: */ print(__LINE__.'+'.$type."+<br />");
                        // Add closing div and br-tag
-                       $OUT .= '</div><br />';
+                       $OUT .= '</div>';
                        $GLOBALS['nav_depth'] = '0';
 
                        $GLOBALS['nav_depth'] = '0';
 
-                       // Run the filter chain
+                       // Run the post-filter chain
                        $ret = runFilterChain('post_youhere_line', array('access_level' => $accessLevel, 'type' => $type, 'content' => ''));
 
                        // Add additional content
                        $OUT .= $ret['content'];
                } // END - if
                        $ret = runFilterChain('post_youhere_line', array('access_level' => $accessLevel, 'type' => $type, 'content' => ''));
 
                        // Add additional content
                        $OUT .= $ret['content'];
                } // END - if
-       }
+       } // END - if
 
        // Return or output HTML code?
        if ($return === true) {
 
        // Return or output HTML code?
        if ($return === true) {
index 5fc5e98124480152d0867b09290c88a2ec7c797d..e7cd475405117269dbc094faf91e9109811fd2f5 100644 (file)
@@ -528,6 +528,7 @@ ul.copyright_box {
        white-space: nowrap;
        font-size: 14px;
        text-align: left;
        white-space: nowrap;
        font-size: 14px;
        text-align: left;
+       margin-bottom: 12px;
 }
 
 .tiny {
 }
 
 .tiny {
index 8be9ce6fdc062937ab189cbdc1731573bcef074a..3292bbcf39969acad8bc254fd9ac6de0903f27e5 100644 (file)
@@ -577,6 +577,7 @@ ul.copyright_box {
        white-space: nowrap;
        font-size: 14px;
        text-align: left;
        white-space: nowrap;
        font-size: 14px;
        text-align: left;
+       margin-bottom: 12px;
 }
 
 .tiny {
 }
 
 .tiny {
index 609a682cc90aadfd8fb710c700ae5e90445d37d4..4811a58fc4d18441d58541373f2119df35f1c25a 100644 (file)
@@ -498,6 +498,7 @@ ul.copyright_box {
        white-space: nowrap;
        font-size: 14px;
        text-align: left;
        white-space: nowrap;
        font-size: 14px;
        text-align: left;
+       margin-bottom: 12px;
 }
 
 .tiny {
 }
 
 .tiny {
index c90aba46e2515cad7771d5349135c362fb6816c8..f694a9bd43b26bc46a4d6b6e0ba224649ee84cad 100644 (file)
@@ -525,6 +525,7 @@ ul, ol {
 .you_are_here {
        white-space         : nowrap;
        font-size           : 14px;
 .you_are_here {
        white-space         : nowrap;
        font-size           : 14px;
+       margin-bottom       : 12px;
 }
 
 .tiny   { font-size            : 10px; }
 }
 
 .tiny   { font-size            : 10px; }