Bug #26483
closed
stdWrap for excludeUidList (HMENU) does not work
Added by most wanted over 13 years ago.
Updated almost 7 years ago.
Description
shouldn't stdWrap work for excludeUidList in HMENU in TYPO3 4.5 now?
http://wiki.typo3.org/TYPO3_4.5#TypoScript_.2F_Frontend
Implemented stdWrap in all properties of all cObjects to enhance flexibility
i tried these 2 typoscript snippets, but they did not work in TYPO3 4.5:
temp.navigation = HMENU
temp.navigation {
### i used TEXT here only to keep the example simple!
excludeUidList.stdWrap.cObject = TEXT
excludeUidList.stdWrap.cObject.value = 10
1 = TMENU
1 {
wrap = <ul>|</ul>
NO = 1
NO {
wrapItemAndSub = <li>|</li>
}
}
}
temp.navigation = HMENU
temp.navigation {
### do not list the current page in the menu:
excludeUidList.stdWrap.data = page:uid
1 = TMENU
1 {
wrap = <ul>|</ul>
NO = 1
NO {
wrapItemAndSub = <li>|</li>
}
}
}
stdWrap has been added to nearly all properties. excludeUidList until now is not among these.
But I guess you can easily add it yourself. Have a look at the file typo3/sysext/cms/tslib/content/hierachicalmenu.php.
This file contains the rendering instructions for an HMENU.
As you can see there are several blocks of code like
if (isset($conf['stdWrap.'])) {
$theValue = $this->cObj->stdWrap($theValue, $conf['stdWrap.']);
}
This block for example adds stdWrap for the property named "stdWrap".
If you want stdWrap for excludeUidList, you only have to add a block similar to that one, but now using $conf['excludeUidList.']
instead of $conf['stdWrap.']
. This block would belong above the lines which deal with "wrap".
thanks for the information!
--- quote ---
stdWrap has been added to nearly all properties. excludeUidList until now is not among these.
--- /quote ---
i guess this is a bug, or is there some special reason for that?
would be great if someone (more competent than me) could fix it. thanks.
my TypoScript snippet was not 100% perfect - here is the correct (NOT WORKING) snippet:
temp.navigation = HMENU
temp.navigation {
### i used TEXT here only to keep the example simple!
excludeUidList.cObject = TEXT
excludeUidList.cObject.value = 10
1 = TMENU
1 {
wrap = <ul>|</ul>
NO = 1
NO {
wrapItemAndSub = <li>|</li>
}
}
}
Patch set 1 of change I10a9814366e69dfdbf87e8ab404ab4d2ce02f4c3 has been pushed to the review server.
It is available at http://review.typo3.org/1813
- Target version set to 4.5.3
Patch set 2 of change I10a9814366e69dfdbf87e8ab404ab4d2ce02f4c3 has been pushed to the review server.
It is available at http://review.typo3.org/1813
- Target version changed from 4.5.3 to 4.5.4
- Status changed from New to Resolved
- % Done changed from 0 to 100
- Status changed from Resolved to Closed
Also available in: Atom
PDF