{** * Articles as news with archive, content template * Date: 10.10.08 * * @package saurus4 * * @author Saurus * *}
{* show configuration area for editor *} {if $in_editor} {* save configuration *} {if $smarty.get.save} {custom_conf_save id=$id open_news=$smarty.get.open_news total_news=$smarty.get.total_news} {/if} {* /save configuration *} {* load configuration *} {custom_conf_load id=$id name="tpl_conf"}
Settings
{* /show configuration area for editor *} {else} {* load configuration *} {custom_conf_load id=$id name="tpl_conf"} {/if} {* set configuration values or default values *} {assign var="total_news" value=$tpl_conf.total_news|default:5} {assign var="open_news" value=$tpl_conf.open_news|default:1} {* the news list *} {init_articles name="articles" position=0 limit=$total_news+$open_news order="date desc" buttons="new,edit,hide,delete"} {$articles_newbutton} {foreach from=$articles item="article" name="articles_loop"} {if $smarty.foreach.articles_loop.iteration <= $open_news} {* open news *}

{$article->buttons}{if $article->show_headline}{$article->title}{/if}

{$article->date} {init_article name="art" id=$article->id} {if $art->lead && $art->body} {$art->lead} {* Read More link from Glossary *} {sysword word="More" type="Visual Design"} {else} {$art->lead} {$art->body} {if $art->forum_allowed} {if $art->comment_count} {sysword word="comments" type="saurus4"} ({$art->comment_count}) | {sysword word="add" type="saurus4"} {else} {sysword word="add comment" type="saurus4"} {/if} {/if} {/if} {* /open news *} {else} {* listed with title news *}

{$article->date} {$article->buttons} {$article->title} {if $article->comment_count}({$article->comment_count}){/if}

{* /listed with title news *} {/if} {/foreach} {* /the news list *} {* archive link *} {if $articles_counttotal > $total_news+$open_news}
{sysword word="archive" type="saurus4"} {/if} {* /archive link *}