Typolink content in menu?

前端 未结 1 768
南方客
南方客 2021-01-28 21:19

I am trying to make a menu that displays the page\'s first content element header and image and have them be links. But the typolink part doesn\'t seem to work for me:



        
相关标签:
1条回答
  • 2021-01-28 21:37

    Just to add give the full working example. Using section.field = uid you can link to the content element itself.

    lib.menu = HMENU
    lib.menu {
        1 = TMENU
        1.NO {
            doNotLinkIt = 1
            wrapItemAndSub = <div>|</div>
            stdWrap.cObject = CONTENT
            stdWrap.cObject {
                table = tt_content
                select {
                    pidInList.field = uid
                }
                renderObj = COA
                renderObj {
    
                    10 = TEXT
                    10.field = header
                    10.typolink {
                        parameter.field = pid
                        section.field = uid
                    }
                }
            }
        }
    }
    
    0 讨论(0)
提交回复
热议问题