Fixed bug ##8913: Empty tabs in DynTabMenu should not be selectable by default
authorBenni Mack <benni.mack@typo3.org>
Sat, 19 Jul 2008 09:10:28 +0000 (09:10 +0000)
committerBenni Mack <benni.mack@typo3.org>
Sat, 19 Jul 2008 09:10:28 +0000 (09:10 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@3897 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
typo3/template.php

index 7a80fa9..2a1c8aa 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2008-07-19  Benjamin Mack  <benni@typo3.org>
+
+       * Fixed bug ##8913: Empty tabs in DynTabMenu should not be selectable by default
+
 2008-07-14  Dmitry Dulepov  <dmitry@typo3.org>
 
        * Fixed bug #8566: Unable to match TS condition when variable is not set
index 21c12d7..5f69dfe 100755 (executable)
@@ -1508,7 +1508,8 @@ $str.=$this->docBodyTagBegin().
                                $JSinit[] = '
                                                DTM_array["'.$id.'"]['.$c.'] = "'.$id.'-'.$index.'";
                                ';
-                               if ($toggle==1) {
+                                       // If not empty and we have the toggle option on, check if the tab needs to be expanded
+                               if ($toggle == 1 && $isNotEmpty) {
                                        $JSinit[] = '
                                                if (top.DTM_currentTabs["'.$id.'-'.$index.'"]) { DTM_toggle("'.$id.'","'.$index.'",1); }
                                        ';