[TYPO3-english] Add a link to the parent menu item in submenu

Daniel Rutzen ardan at gmx.net
Fri Sep 4 15:03:47 CEST 2009


Hello,

I have a horizontal main menu and a vertical submenu. In the submenu, 
there are ony the sub-items listed from the parent main menu item.

Let's say I have a main menu item 'cars' and sub pages for colors.
I've got it working that the second menu now shows the coresponding sub 
items, each in a <li></li> Tag:

<li>blue cars</li>
<li>red cars</li>
<li>green cars</li>


What I would like to have is, that the first <li>-Element has a link to
the parent main menu item, and the sub items are in another <ul> within 
the parent <li>

<ul>
<li>CARS
  <ul>
   <li>blue cars</li>
   <li>red cars</li>
   <li>green cars</li>
  </ul>
</li>
</ul>


This is a snippet from my HTML test template, how it should like in the 
end....


<ul id="secondmenu">
<!-- ###leftnavi### start -->

<li><a href="#" class="first">CARS</a>
  <ul>
  <li><a href="#">blue cars</a></li>
  <li><a href="#">red cars</a></li>
  <li><a href="#">green cars</a></li>
  </ul>
</li>

<!-- ###leftnavi### end -->
</ul><!-- secondmenu end -->




I hope I was able to explain what I am trying to do here :-)


More information about the TYPO3-english mailing list