[eluser]dvogel[/eluser]
I'm using the template parser for building my page from a template. The view is the real page content. I'm reading weblog items and placing them in the page using the following code
Code:
<div id="weblog">
{weblog_records}
<div class="entry">
<div class="header">
<div><a href="?/weblog/index/{id}">{title}</a></div>
<div>door {name} {date}@{time}</div>
</div>
<div class="body">{message}</div>
</div>
{/weblog_records}
</div>
But i want the messages to be truncated. This will be done in the controller. The array containing the title, name, date, time and message gets a new variable messageTruncated which is true when the message was to long and was truncated. Within the {weblog_records}...{/weblog_records} iteration I want to check this boolean so I can place a html link to the complete message like this code:
Code:
<?php
if ($messageTruncated == true)
{
echo '<a href="?/weblog/index/{id}">read more...</a>''
}
?>
How can i access the variables within the current entry of the {weblog_records}...{/weblog_records} iteration?