[eluser]georgerobbo[/eluser]
Are you unable to have more than one foreach loop in php? When the first foreach loop is active the second one doesn't function. However as soon as I comment the first loop the second loop functions.
Code:
<div id="panel">
<?php foreach ($item['random_single'] as $item): ?>
<div id="preview">
<div id="preview_item">
<img src="<?php echo base_url(); ?>public/uploads/<?php echo $item['filename'];?>.jpg" alt="" />
</div>
<div id="gradient">
</div>
</div>
<div id="meta">
<h2><a href="<?php echo site_url(); ?>/archive/<?php echo $item['permalink']; ?>"><?php echo $item['title']; ?></a></h2>
<h5><small>Author:</small> <a href="<?php echo site_url(); ?>/profile/<?php echo $item['username']; ?>"><?php echo $item['author']; ?></a></h5>
<h5><small>Uploaded:</small> <?php echo $item['time']; ?> ∼ <?php echo $item['date']; ?></h5>
<h5><small>Tags:</small></h5>
<p><small><?php echo $item['description']; ?></small></p>
</div>
<?php endforeach; ?>
</div>
<div id="dual">
<div class="dualpanel">
<h2 class="title">Whats New</h2>
</div>
<div class="dualpanel">
<h2 class="title">Categories</h2>
<ul class="category">
<?php foreach ($item['list_category'] as $item): ?>
<li><a href="#"><?php echo $item['category']; ?></a></li>
<?php endforeach; ?>
</ul>
</div>
</div>
</div>