[TYPO3] creating tmenu/hmenu from alias of TYPO3 pages

Tyler Kraft tyler.kraft at netefficiency.co.uk
Mon Jan 21 09:00:46 CET 2008


Hi Darko,

Christophers example is as good as anything I'd post up. What I did was 
very similar but I used a before and an after item, and I made both of 
them COA objects so I could pull in various things and use 'if' 
statements as well. All relatively simple TS once you get going with it 
imho.

Good luck,
Ty



> Simple TS example--generates a set of links where, if there is content
> in the description field of the page record, that content is shown
> after the initial link with a "•" between them. Not commented, but as
> self-explanatory as TS ever is :-)
> 
> 
> lib.info_menu = HMENU
> lib.info_menu {
> 	1 = TMENU
> 	1 {
> 		wrap = <ul>|</ul>
> 		noBlur = 1
> 
> 		NO {
> 			wrapItemAndSub = <li>|</li>
> 
> 			after.cObject = HTML
> 			after.cObject {
> 				value {
> 					data = field:description
> 					typolink {
> 						parameter.data = field:uid
> 						wrap = &nbsp;&middot;&nbsp;
> 					}
> 
> 					if {
> 						isTrue.data = field:description
> 					}
> 				}
> 			}	
> 		}
> 
> 		ACT = 1
> 		ACT < .NO
> 		ACT {
> 			ATagParams = clas="active"
> 		}
> 	}
> 	
> 	2 < .1
> 	3 < .1
> }


More information about the TYPO3-english mailing list