bludit/admin/views/manage-posts.php

27 lines
628 B
PHP
Raw Normal View History

2015-05-05 03:00:01 +02:00
<h2 class="title"><i class="fa fa-file-text-o"></i> Manage Posts</h2>
<?php makeNavbar('manage'); ?>
<table class="table-bordered table-stripped">
<thead>
<tr>
<th>Title</th>
<th>Published date</th>
<th>Modified date</th>
</tr>
</thead>
<tbody>
<?php
foreach($posts as $Post)
{
echo '<tr>';
echo '<td><a href="'.HTML_PATH_ADMIN_ROOT.'edit-post/'.$Post->key().'">'.(empty($Post->published())?'[DRAFT] ':'').(empty($Post->title())?'[Empty title] ':$Post->title()).'</a></td>';
echo '<td>'.$Post->date().'</td>';
echo '<td>'.$Post->timeago().'</td>';
echo '</tr>';
}
?>
</tbody>
</table>