<?php
$db = new Database();
$sql = 'SELECT * FROM users';
$arr_users = $db->get_all($sql);
?>
<table border="1" align="center">
<tr align="center">
<td width="250px">User</td>
<td width="100px">Type</td>
<td width="150px" colspan="2"><small>Add,Modify,Delete</small></td>
</tr>
<?php foreach ($arr_users as $value):?>
<tr align="center">
<td align="left"><?php echo $value->username?></td>
<td><?php echo $value->user_type?></td>
<td><a href="index.php?id=<?php echo $value->user_id?>">Edit</a></td>
<td><a href="index.php?del&user_id=<?php echo $value->user_id?>">Delete</a></td>
</tr>
<?php endforeach;?>
<tr align="right"><td colspan="4"><a href="index.php?id=new">Add New User</a></td></tr>
</table>
NOTE: try to insert a XXS! >"<'
|