Ejemplo n.º 1
0
 function index()
 {
     $this->load->helper('date');
     $Model = new mBlogPost();
     $Model->list_all(FALSE);
     data('TableData', $Model);
     $this->display('blog/list');
 }
Ejemplo n.º 2
0
 function index()
 {
     $this->output->cache(30);
     $Blog = new mBlogPost();
     $Posts = $Blog->list_all(true)->get();
     data('Posts', $Posts);
     $this->display('list');
 }
Ejemplo n.º 3
0
 function index()
 {
     $this->output->cache(30);
     $this->config->set_item('class_as_root', false, 'ifx');
     data('scrollHeader', true);
     $LatestPosts = new mBlogPost();
     data('Posts', $LatestPosts->list_all(TRUE, 3)->get());
     $this->display('homepage');
 }
Ejemplo n.º 4
0
<div class="recent-posts">
    <h3>Recent Posts</h3>
    <?php 
$Other = new mBlogPost();
$All = $Other->list_all()->get();
?>
    <ul>
        <?php 
foreach ($All as $OtherPost) {
    ?>
            <?php 
    if (isset($Post) && $OtherPost->id() == $Post->id()) {
        continue;
    }
    ?>
            <li>
                <span class="post-date"><?php 
    echo date('d.m.y', $Published->updated);
    ?>
</span>
                <a href="<?php 
    echo posturl($OtherPost);
    ?>
"><img src="<?php 
    echo $OtherPost->mainimage;
    ?>
"/><?php 
    echo $OtherPost->title;
    ?>
</a>
            </li>