[TYPO3] displaying mininews on the front page

racco raczek at open.infi.pl
Sun Feb 26 13:41:09 CET 2006

racco napisał(a):
> Hello!
> I am trying to display a splash of mininews on my front page. I don't 
> want to have it displayed through all site but only on one particular 
> page (root page). I know how to display mininews using TypoScript, but 
> it renders it on all subpages. How to do it only on one page?
> I was trying to use some conditions within my TS, but they didn't work:
> temp.mainTemplate = TEMPLATE
> temp.mainTemplate {
> ...
> # [treeLevel = 0]
>   subparts.news-pi < plugin.tx_mininews_pi1
>   subparts.news-pi.CMD = FP
>  #[PIDupinRootline = 399]
>   subparts.news-pi < temp.nothing
> ...
> }
> Above I was trying to limit plugin rendering only to page which was 
> RootLevel, but it didn't work. Then I was trying to display some dummy 
> content on all pages on the rootline apart from root site (pid=399) - 
> also nothing. It seems like conditions don't work at all in TEMPLATE 
> object.
> Any ideas?
> thx
> racco
OK, I got it working now.

Here's what I did:

I copied temp.mainTemplate = TEMPLATE
First one contained mininews
  subparts.news-pi < plugin.tx_mininews_pi1
Second one had dummy contnet in place of mininews
  subparts.news-pi < temp.nothing

Before first one I put no condition.

Before second temp.mainTemplate I put condiotion
  [PIDupinRootline = 399]
and just right at the end of it condition [global].

In the definition of the second temp.mainTemplate do not forget to clear 
it using temp.mainTemplate >

that's all, it is fine now!


More information about the TYPO3-english mailing list