Feature #25133

TMENU has no typolink function

Added by Simon Schaufelberger about 10 years ago. Updated about 5 years ago.

Should have
Target version:
Start date:
Due date:
% Done:


Estimated time:
PHP Version:
Sprint Focus:


i use this as a base:

temp.tmenuUl = HMENU
temp.tmenuUl {
    entryLevel = 0
    1 = TMENU
    1 {
        noBlur = 1
        wrap = <ul>|</ul>
        NO {
            ATagBeforeWrap = 1
            wrapItemAndSub = <li>|</li>
            stdWrap.htmlSpecialChars = 1

now what i am tying to do is to attach a hash value after the link href and tried the following (important, if you want to read the hash with javascript or ajax):
temp.tmenuUl {
    1 {
        NO {
            stdWrap.typolink.additionalParams = #test

which is sadly not working.

i know there are workarounds but they are kind of difficult and ugly.

can this be implemented and still be backwards compatible?

(issue imported from #M17709)


Updated by Simon Schaufelberger about 10 years ago

oh, the bugtracker does not encode html...

the line above was (encoded):

wrapItemAndSub = [li]|[/li]


Updated by Steffen Kamper about 10 years ago

Please look to tsRef first!
additionalParams is available.


Updated by Simon Schaufelberger about 10 years ago

i did that but the thing does not what i want.

i think i found a bug here:

typo3\sysext\cms\tslib\class.tslib_menu.php line 1576 in trunk

 * Creates the <A> tag parts for the current item (in $this->I, [A1] and [A2]) based on other information in this array (like $this->I['linkHREF'])
 * @return    void
 * @access private
function setATagParts()    {
    $this->I['A1'] = '<a '.t3lib_div::implodeAttributes($this->I['linkHREF'],1).' '.$this->I['val']['ATagParams'].$this->I['accessKey']['code'].'>';
    $this->I['A2'] = '</a>';

here no additionalParams are attached to the link even if using this ts:
temp.tmenuUl {
    1 {
        additionalParams = #test

next try while digging deeeeeper into the core:
I found out that this works:
temp.tmenuUl {
    1 {
        addParams = &abc=3
        # additionalParams = &a=b     # does NOT work!

but additionalParams don't get respected in any way.

This also does NOT work:

temp.tmenuUl {
    1 {
          addParams = <HASH>3

but this is a problem of typolink...


Updated by Chris topher almost 8 years ago

  • Category deleted (Communication)
  • Target version deleted (0)

Updated by Mathias Schreiber over 6 years ago

  • Status changed from New to Needs Feedback
  • Assignee set to Mathias Schreiber

adding &#hash doesn't cut it, right?


Updated by Simon Schaufelberger over 6 years ago

oh, i don't even remember where i have used that typoscript. It's 4 years ago :D Need to setup a test environment...


Updated by Alexander Opitz almost 6 years ago

Any news on this issue?


Updated by Simon Schaufelberger almost 6 years ago

still doesn't work as the menu rendering is still the same since ages...


Updated by Alexander Opitz almost 6 years ago

@Simon: Last time you wrote "Need to setup a test environment...". Your answer now is more like "you didn't test but assume that it didn't change", do I understand this correct?


Updated by Simon Schaufelberger almost 6 years ago

I didn't have a look into the source code but yes, I'm quite sure that it is still the same as I follow the release notes and there was nothing about it ;)

Could you have a look into it? Otherwise I will do it in the next few days.


Updated by Susanne Moog over 5 years ago

FYI: additionalParams still does not work this way (as it expects url params, not anchors) but the behavior can be achieved by for example:

stdWrap.typolink.parameter.dataWrap = {field:uid}#navi


Updated by Alexander Opitz over 5 years ago

  • Assignee changed from Mathias Schreiber to Simon Schaufelberger

Hi Simon,

what's the state of this issue?


Updated by Alexander Opitz about 5 years ago

  • Status changed from Needs Feedback to Closed
  • Assignee deleted (Simon Schaufelberger)

No feedback within the last 90 days => closing this issue.

If you think that this is the wrong decision or experience this issue again, then please write to the mailing list typo3.teams.bugs with issue number and an explanation or open a new ticket and add a relation to this ticket number.

Also available in: Atom PDF