I have encountered an issue with the news module. After applying {news} on home page and selected the article, the layout broke only to display text mode. Here is the code I used inside summary_news templated based on Simplex.
Code: Select all
{strip}
<!-- .news-summary wrapper -->
<article class='news-summary'>
<span class='heading'><span>News</span></span>
<ul class='category-list cf'>
{foreach from=$cats item='node'}
{if $node.depth > $node.prevdepth}
{repeat string='<ul>' times=$node.depth-$node.prevdepth}
{elseif $node.depth < $node.prevdepth}
{repeat string='</li></ul>' times=$node.prevdepth-$node.depth}
</li>
{elseif $node.index > 0}</li>
{/if}
<li{if $node.index == 0} class='first'{/if}>
{if $node.count > 0}
<a href='{$node.url}'>{$node.news_category_name}</a>{else}<span>{$node.news_category_name} </span>{/if}
{/foreach}
{repeat string='</li></ul>' times=$node.depth-1}</li>
</ul>
{foreach from=$items item='entry'}
<!-- .news-article (wrapping each article) -->
<section class='news-article'>
<a href='{$entry->moreurl}' title='{$entry->title|cms_escape:htmlall}'>
<header>
{CGSmartImage filter_croptofit="256,180,c" quality='65' src="{$entry->file_location}/{$entry->fieldsbyname.Images->value}" alt="{$entry->title}"}
<h2>{$entry->title|cms_escape}</h2>
<div class='meta cf'>
<time class='date' datetime='{$entry->postdate|date_format:'%Y-%m-%d'}'>
<span class='day'> {$entry->postdate|date_format:'%d'} </span>
<span class='month'> {$entry->postdate|date_format:'%b'} </span>
</time>
<span class='author'> {$author_label} {$entry->author} </span>
<span class='category'> {$category_label} {$entry->category}</span>
</div>
</header>
{if $entry->summary}
<p>{eval var=$entry->summary|strip_tags}</p>
<span class='more'>{$entry->morelink} →</span>
{else if $entry->content}
<p>{eval var=$entry->content|strip_tags}</p>
{/if}
</a></section>
<!-- .news-article //-->
{/foreach}
<!-- news pagination -->
{if $pagecount > 1}
<span class='paginate'>
{if $pagenumber > 1}
{$firstpage} {$prevpage}
{/if}
{$pagetext} {$pagenumber} {$oftext} {$pagecount}
{if $pagenumber < $pagecount}
{$nextpage} {$lastpage}
{/if}
</span>
{/if}
</article>
<!-- .news-summary //-->
{/strip}
Here is my current template layout
Code: Select all
{strip}
{process_pagedata} <!-- Adds page specific metadata to the page -->
{MleCMS action='init'}
{cms_lang_info assign='nls'}
{/strip}
<!doctype html>
<__html lang="{$nls->htmlarea()}">
<head>
<title>{title} | {sitename}</title> <!-- Title of the page | Site name from Global Settings -->
<meta name='viewport' content='initial-scale=1.0 maximum-scale=1.0 user-scalable=no' />
<meta name='HandheldFriendly' content='true' />
{metadata} <!-- Adds Global Metadata to the page -->
{cms_stylesheet} <!-- Adds attached stylesheets to the page -->
{* learning IE lower then Version 9 some html5 *}
<!--[if lt IE 9]>
<__script__ src="//html5shiv.googlecode.com/svn/trunk/html5.js"></__script>
<![endif]-->
</head>
</__body>
<header role="banner">
<div class="container centered">
<div class="ads">[..insert advertisment...]</div>
<hgroup>
<h1>
<a href='{root_url}' title='{sitename}'>
<img src='{uploads_url}/images/cwlogo-a.png' width='379' height='90' alt='{sitename}' />
</a>
</h1><!-- .logo //-->
<!-- Site name from Global Settings -->
<p>For the Woman of Success, Style & Substance</p>
</hgroup>
</div>
</header>
<nav role="navigation">
{menu number_of_levels="1"} <!-- Show all the menu buttons -->
</nav>
<div id="main-content" class="container centered">
<section id="content">
<!-- h2>{title}</h2 --> <!-- Title of the page -->
<article role="main">
{content} <!-- Page content -->
</article><!-- end [role="main"] -->
</section>
<aside>
{content block=second_content label="My second content block"} <!-- Create a second content block -->
{global_content name='social-network'}
{global_content name='videoclip'}
</aside>
</div> <!-- end #main-content -->
<footer>
<div class="container centered">
{global_content name="footer"} <!-- Extract all footer code to a global content block -->
</div>
</footer>
<__body>
</__html>