I need to make an email link in a table.  The username is displayed as 
text; I need it to be a link through which I can send email.  Is this 
possible in php?  The following is the code for that I'm using:

function show_logged_users($user) {

   $query = "select distinct uid, cn from log left join ldap.ldap on 
log.user like ldap.ldap.uid order by ldap.ldap.sn";

   $result = mysql_query($query);

   if (($result) && (mysql_num_rows($result) > 0)) {
     while ($line = mysql_fetch_row($result)) {
       $opts[$line[0]] = $line[1];
   } else {
     $opts[0] = "Error in show_logged_users()";

   show_select($opts, $user);

     <font face="Arial, Helvetica, sans-serif" size="-1" 
     <select name="user">
     <? show_logged_users($user) ?>

What I need is the <? show_logged_users($user) ?> statement to turn itself 
into a mailto: statement to that clicking on the user name will bring up an 
email addressed to username @domain.com  Is this possible?  Is there any 
code out there that I can get a look at?



PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to