21 lines
606 B
PHP
21 lines
606 B
PHP
|
|
<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>
|
||
|
|
<td><?=$cat->name?></td>';
|
||
|
|
<td><a style="float: right" href="/portal/edit?id=<?=$cat->id?>">Edit</a></td>';
|
||
|
|
<td><form method="post" action="/portal">
|
||
|
|
<input type="hidden" name="id" value="<?=$cat->id?>" />
|
||
|
|
<input type="submit" name="submit" value="Delete" />
|
||
|
|
</form></td>
|
||
|
|
</tr>
|
||
|
|
<?php } ?>
|
||
|
|
</thead>
|
||
|
|
</table>
|