[TYPO3-english] Conditional news display by Typoscript
Ahmed Moosavi
r.mesbah at gmail.com
Thu Nov 12 13:16:40 CET 2009
Hi,
This is the typoscript I use :
tmp.brknews < plugin.tt_news
tmp.brknews {
limit= 1
code >
code = LIST
pid_list >
pid_list = 4
templateFile = fileadmin/styles/v2/breakingnews.html
singlePid = 22
}
page.10 = TEMPLATE
page.10 {
template = FILE
template.file = fileadmin/styles/index.htm
workOnSubpart = WHOLEPAGE
subparts.BREAKING < tmp.brknews
}
breakingnews.html : (I use it by a jQuery ticker that works by <li> tag)
<!-- ###TEMPLATE_LIST### begin -->
<div id="breakingnews">
<ul>
<!-- ###CONTENT### begin-->
<!-- ###NEWS### begin -->
<li> ###NEWS_TITLE### </li>
<!-- ###NEWS### end-->
<!-- ###CONTENT### end -->
</ul>
</div>
<!-- ###TEMPLATE_LIST### end -->
Regards
JoH asenau wrote:
>> I'm trying to make a news site and I have some parts for "Breaking
>> News" on top of the page with a red background , so I need it could
>> be displayed ONLY when it has some records. I've changed the "no news
>> in list." to blank but still the container red "div" displayed :(
>>
>> Is there any typescript solution to get the marker or subpart by a
>> condition and check whether any record is in the page or not ?
>
> Depends on how you applied the "red div" - do you have any code to show us?
>
> Joey
>
More information about the TYPO3-english
mailing list