Fixed bug #17360: beforeWrap/afterWrap properties of TMENUITEM not working anymore
authorFrancois Suter <francois.suter@typo3.org>
Fri, 4 Feb 2011 15:51:56 +0000 (15:51 +0000)
committerFrancois Suter <francois.suter@typo3.org>
Fri, 4 Feb 2011 15:51:56 +0000 (15:51 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/branches/TYPO3_4-5@10383 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
typo3/sysext/cms/tslib/class.tslib_menu.php

index c86b710..59efbea 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2011-02-04  Francois Suter  <francois.suter@typo3.org>
+
+       * Fixed bug #17360: beforeWrap/afterWrap properties of TMENUITEM not working anymore (Thanks to Jo Hasenau)
+
 2011-02-03  Steffen Kamper  <steffen@typo3.org>
 
        * Fixed bug #17407: Pagetree cause endless loop in ExtJS events
index d57ba48..b9a6b98 100644 (file)
@@ -1927,10 +1927,14 @@ class tslib_tmenu extends tslib_menu {
                                $res=$this->I['A1'].$res.$this->I['A2'];
                        }
                }
-               $pref = isset($this->I['val'][$pref.'.'])
-                       ? $this->WMcObj->stdWrap($this->I['val'][$pref], $this->I['val'][$pref.'.'])
+               $processedPref = isset($this->I['val'][$pref . '.'])
+                       ? $this->WMcObj->stdWrap($this->I['val'][$pref], $this->I['val'][$pref . '.'])
                        : $this->I['val'][$pref];
-               return $this->tmpl->wrap($res.$pref, $this->I['val'][$pref.'Wrap']);
+               if (isset($this->I['val'][$pref . 'Wrap'])) {
+                       return $this->tmpl->wrap($res . $processedPref, $this->I['val'][$pref . 'Wrap']);
+               } else {
+                        return $res . $processedPref;
+               }
        }
 
        /**