bludit/admin/views/manage-pages.php

39 lines
1.3 KiB
PHP
Raw Normal View History

2015-09-08 02:51:48 +02:00
<h2 class="title"><i class="fa fa-file-text-o"></i><?php $Language->p('Manage pages') ?></h2>
2015-05-05 03:00:01 +02:00
<?php makeNavbar('manage'); ?>
<table class="table-bordered table-stripped">
<thead>
<tr>
2015-07-04 00:36:37 +02:00
<th><?php $Language->p('Title') ?></th>
<th><?php $Language->p('Parent') ?></th>
2015-09-15 02:47:02 +02:00
<th><?php $Language->p('Friendly URL') ?></th>
<th class="text-centered"><?php $Language->p('Position') ?></th>
2015-05-05 03:00:01 +02:00
</tr>
</thead>
<tbody>
<?php
foreach($pagesParents as $parentKey=>$pageList)
{
foreach($pageList as $Page)
{
if($parentKey!==NO_PARENT_CHAR) {
$parentTitle = $pages[$Page->parentKey()]->title();
}
else {
$parentTitle = '';
}
echo '<tr>';
2015-08-12 22:15:17 +02:00
echo '<td>'.($Page->parentKey()?NO_PARENT_CHAR:'').'<a href="'.HTML_PATH_ADMIN_ROOT.'edit-page/'.$Page->key().'">'.($Page->published()?'':'<span class="label label-outline label-red smaller">'.$Language->g('Draft').'</span> ').($Page->title()?$Page->title():'<span class="label label-outline label-blue smaller">'.$Language->g('Empty title').'</span> ').'</a></td>';
2015-05-05 03:00:01 +02:00
echo '<td>'.$parentTitle.'</td>';
2015-09-15 02:47:02 +02:00
echo '<td><a target="_blank" href="'.$Page->permalink().'">'.$Url->filters('page').'/'.$Page->key().'</a></td>';
echo '<td class="text-centered">'.$Page->position().'</td>';
2015-05-05 03:00:01 +02:00
echo '</tr>';
}
}
?>
</tbody>
2015-07-04 00:36:37 +02:00
</table>