bludit/bl-kernel/admin/views/categories.php

34 lines
802 B
PHP
Raw Normal View History

2017-04-17 12:49:03 +02:00
<?php
echo Bootstrap::pageTitle(array('title'=>$L->g('Categories'), 'icon'=>'grid-three-up'));
2017-04-17 12:49:03 +02:00
echo Bootstrap::link(array(
'title'=>'Add a new category',
'href'=>HTML_PATH_ADMIN_ROOT.'new-category',
'icon'=>'plus'
));
2017-04-17 12:49:03 +02:00
echo '
<table class="table table-striped mt-3">
<thead>
<tr>
<th class="border-bottom-0" scope="col">Name</th>
<th class="border-bottom-0" scope="col">URL</th>
</tr>
</thead>
<tbody>
2017-04-17 12:49:03 +02:00
';
2017-05-16 00:46:20 +02:00
$categories = $dbCategories->getKeyNameArray();
foreach ($categories as $categoryKey=>$category) {
2017-04-17 12:49:03 +02:00
echo '<tr>';
echo '<td><a href="'.HTML_PATH_ADMIN_ROOT.'edit-category/'.$categoryKey.'">'.$category.'</a></td>';
echo '<td><a href="'.DOMAIN_CATEGORIES.$categoryKey.'">'.$Url->filters('category', false).$categoryKey.'</a></td>';
2017-04-17 12:49:03 +02:00
echo '</tr>';
}
echo '
</tbody>
2017-04-17 12:49:03 +02:00
</table>
';