[TYPO3] tt_news category in typoscript

Allan Jacobsen Allan.J at cobsen.dk
Wed Feb 14 15:23:47 CET 2007


Hi

I am trying to find a way to make a tt_news single view page look
different for news records from different categories.
I searched the docs and found that there should be a register var called
register:newsCategoryUid set for the current tt_news record, but it does
not seem to work, but then again I may be using it wrongly. Here is my
typoscript:

lib.header = COA
lib.header {
  10 = TEXT
  10.value = <img src="fileadmin/templates/hc_bg_top_blog.jpg">
  20 = TEXT
  20.data = register:newsCategoryUid
  20.wrap = <div class="news-kategory">|</div>
}

For now I just want to see if it is set, but what I really want is to set
the image path in 10 to 3 diffent values according to the category of
the tt_news record.
Any good ideas ?

Best regards
Allan Jacobsen


More information about the TYPO3-english mailing list