Files
HotLunches/contacts.display.row.admin.php
2026-10-19 15:22:52 -07:00

57 lines
2.5 KiB
PHP

<?php
require_once("include/globals.php");
if (SessionActive() != 1 || ! UserLoggedIn()) {
header("Location: /");
exit();
}
if (isset($home_email) && strlen($home_email) > 0) {
$home_email = "<a href='mailto:$home_email'>$home_email</a>";
}
$userid = db_getVal("select userid from users where record_num = $user_num");
$edit_icon = "<img src='images/icons/edit24.png' alt='Edit Contact Information' border='0'>";
$delete_icon = "<img src='images/icons/delete24.png' alt='Delete Contact Information' border='0'>";
$user_icon = "<img src='images/icons/user24.png' alt='Manage User Account' border='0'>";
$student_icon = "<img src='images/icons/groupofusers24.png' alt='Edit Student' border='0'>";
?>
<tr height='1'>
<td align='center' colspan='5'></td>
</tr>
<tr class='<?php echo($bgclass) ?>'>
<td width='80' align='right'><?php displayLanguageText('CONTACT-CONTACT'); ?>: &nbsp;&nbsp;</td>
<td align='left' valign='top'><?php echo("$parent") ?></td>
<td align='left' valign='top'><?php echo("$student") ?></td>
<td></td>
</tr>
<tr class='<?php echo($bgclass) ?>'>
<td align='right' valign='top'><?php displayLanguageText('CONTACT-HOME'); ?>: &nbsp;&nbsp;</td>
<td align='left' valign='top'><?php echo($home_phone) ?></td>
<td align='left' valign='top'><?php echo($home_email) ?></td>
<td align='right'>
<table>
<tr>
<td align='center'>
<a href='?action=<?php echo($action) ?>&naction=edit&record_num=<?php echo($contact_num) ?>' title='Edit Contact Information'><?php echo($edit_icon) ?></a>
</td>
<td align='center'>
<a href='?action=<?php echo($action) ?>&naction=delete&record_num=<?php echo($contact_num) ?>' title='Delete Contact Information'><?php echo($delete_icon) ?></a>
</td>
<td align='center'>
<a href='?action=users&naction=lookup&userid=<?php echo($userid) ?>' title='Manage User Account <?php echo($userid) ?>'><?php echo($user_icon) ?></a>
</td>
<td align='center'>
<a href='?action=students&naction=edit&record_num=<?php echo($student_num) ?>' title='Edit Student <?php echo($student) ?>'><?php echo($student_icon) ?></a>
</td>
</tr>
</table>
</td>
</tr>
<tr height='1'>
<td align='center' colspan='5'></td>
</tr>