sure
I can try and help... I haven't tested any of this code, but it looks like it should work...
In include/client/header.inc.php, you'll need to add a link to the listing...
<li><a class="home" href="index.php">Home</a></li>
<li><a href="staff_listing.php">Staff</a></li> Add this
Then add in the main directory a file called staff_listing.php with the following:
<?php
require('client.inc.php');
require(CLIENTINC_DIR.'header.inc.php');
$sql = "SELECT * FROM " . STAFF_TABLE . ", " . DEPT_TABLE ." WHERE " . STAFF_TABLE . ".dept_id = " . DEPT_TABLE . ".dept_id";
$users = db_query($sql);
if($users && db_num_rows($users)):?>
<div class="msg">Staff Members</div>
<table border="0" cellspacing=0 cellpadding=2 width="100%">
<tr>
<th>Name</th>
<th>Dept</th>
<th>Email</th>
<th>Phone</th>
<th>Mobile</th>
</tr>
<?
$class = 'row1';
while ($row = db_fetch_array($users)) {
$name=ucfirst($row.' '.$row);
$ext=$row?' Ext '.$row:'';
?>
<tr class="<?=$class?>" id="<?=$row?>">
<td><?=$name?> </td>
<td><?=$row?> </td>
<td><?=$row?> </td>
<td><?=Format:($row)?> <?=$ext?></td>
<td><?=Format:($row)?> </td>
</tr>
<?
$class = ($class =='row2') ?'row1':'row2';
}
?>
</table>
<?
else:
echo "<b>Problems displaying directory</b>";
endif;
echo "</div>";
require(CLIENTINC_DIR.'footer.inc.php');
?>
Let me know if that works...