2023-01-25 14:25:37 +00:00
|
|
|
<h2>Categories</h2>
|
|
|
|
|
<a class="new" href="addcategory.php">Add new category</a>
|
|
|
|
|
<table>
|
|
|
|
|
<thead>
|
|
|
|
|
<tr>
|
|
|
|
|
<th>Name</th>
|
|
|
|
|
<th style="width: 5%"> </th>
|
|
|
|
|
<th style="width: 5%"> </th>
|
|
|
|
|
</tr>
|
|
|
|
|
<?php foreach ($cats as $cat) { ?>
|
|
|
|
|
<tr>
|
2023-01-25 15:37:06 +00:00
|
|
|
<td><?=$cat->name?></td>
|
|
|
|
|
<td><a style="float: right" href="/portal/edit?cat_id=<?=$cat->id?>">Edit</a></td>
|
|
|
|
|
<td><form method="post" action="/portal/">
|
|
|
|
|
<input type="hidden" name="cat_id" value="<?=$cat->id?>" />
|
2023-01-25 14:25:37 +00:00
|
|
|
<input type="submit" name="submit" value="Delete" />
|
|
|
|
|
</form></td>
|
|
|
|
|
</tr>
|
|
|
|
|
<?php } ?>
|
|
|
|
|
</thead>
|
|
|
|
|
</table>
|