Posted By

simongrout on 06/11/09


Tagged

menu typoscript navigation


Versions (?)



Who likes this?

1 person has marked this snippet as a favorite

rob-ot


A simple navigation menu in typoscript with different classes on the first and last elements


Published in: TYPO3 



Website Promotion
DIRECTORY
is a crucial factor for all websites that need to gain better organic search engine rankings and increase website traffic.
Submitting your website as part of your Web Promotion strategy to our SEO friendly and high traffic Business Directory for review is an excellent way to gain a valuable backlink and increase your websites visibility online.

Submit Site


URL: http://3ev.com

Creates a list of links from a folder of TYPO3 content. The first and last item in the list can be given a different HTML class; this allows you to style them differently. For example, you may want dividers after all of your menu items except for the last one.

This a simple piece of typoscript, but it took me a while to track down the right answer.

special.value is the ID of the page or folder you want want to create a menu from.

Expand | Embed | Plain Text
  1. lib.navmenu = HMENU
  2. lib.navmenu {
  3. special = directory
  4. special.value = 1
  5. 1 = TMENU
  6. 1.NO {
  7. linkWrap = <li class="first">|</li>|*|<li>|</li>|*|<li class="last">|</li>
  8. }
  9. }

Report this snippet 

You need to login to post a comment.