Hi there,
I need to send an email in php - though the recipient is derived from a mysql query. Which is the best way to go about it. Do i just do the following:
$emailrec = "<?php $query="SELECT Email FROM members WHERE Username='".$_SESSION['Username']."'";
$Email=mysql_query($query) or die(mysql_error());
while($row=mysql_fetch_assoc($Email)){
foreach($row as $cname => $cvalue){
print "$cvalue\t";
}
print "\r\n";
}?>"
or is there a better way to do so ? Sorry but i'm still pretty new to PHP.
Thanks in advance to anyone who posts....


