Location: PHPKode > projects > The Invisible Mailer (TiM) > tim/contactslist.php
<?php
include "common.php";
?>

<HTML>
<HEAD>
<TITLE>Contacts (TiM)</TITLE>
</HEAD>
<BODY TOPMARGIN=0 LEFTMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0>
<TABLE WIDTH="100%" CELLPADDING=0 CELLSPACING=0 BORDER=0>
<TR><TD BGCOLOR=#BBBBFF><IMG SRC='popupleft.gif'></TD>
<TD ALIGN=RIGHT BGCOLOR=#BBBBFF><IMG SRC='contacts.gif'></TD>
</TR>
<TR><TD BGCOLOR=#FFFFFF COLSPAN=2>
<TABLE WIDTH="100%" CELLPADDING=4 CELLSPACING=0 BORDER=0>
<TR><TD>
<FONT FACE="Tahoma,Verdana,Arial,Helvetica,sans-serif" SIZE="-1">
<CENTER><B>Add recipient</B><BR>
<SPAN STYLE="font-size: 8pt;">
by [<A HREF='<?php echo $PHP_SELF; ?>?show=nick'>Nick</A> | <A HREF='<?php echo $PHP_SELF; ?>?show=fullname'>Full Name</A>]
</CENTER><P>
<?php

if ($show != "fullname") {
$contacts = $mailstore->rawQuery("select cnick, cmail from contacts order by cnick asc");
}
else {
$contacts = $mailstore->rawQuery("select cname, cmail from contacts order by cname asc");
}

while ($contact = mysql_fetch_array($contacts)) {
if ($show != "fullname") {
	echo "<LI><A HREF='getmail.php?nick=".$contact['cnick']."'>".$contact['cnick']."</A> ". $contact['cmail']."\n";
}
else {
	echo "<LI><A HREF='getmail.php?nick=".$contact['cnick']."'>".$contact['cname']."</A>\n";

}
}

?>
</SPAN>
</FONT>
</TD></TR>
</TABLE>
</TD></TR>
</TABLE>
</BODY>
</HTML>
Return current item: The Invisible Mailer (TiM)