Since it's a message system the $row is defined inside of the while loop. I'm not looking for a direct answer though it would be nice. I'm actually having difficulty with the MySQL documentation. I eventually got used to W3C's and after a redesign can now figure out Apache. So I'm much more interested in learning how to independently research the topic so I can at least make more of an educated guess versus an empty handed sort of question. Here is the minimal though most applicable code I think is relevant to achieving this goal...
Code: Select all
if (!isset($_GET['folder'])) {$result1 = mysql_query("SELECT id, id_from, date_0, date_1, message, subject FROM `public_private_messages` WHERE id_for = '".$_SESSION['member']."' OR id_for_folder = 'New'");} // AND id_for_folder = 'Read'
if (!$result1) {$_SESSION['error'] = mysql_error(); header("location:messages.php?error");}
while($row = mysql_fetch_array($result1))
{
echo '<tr id="message_'.$row['id'].'"><td><input class="checkbox" type="checkbox" value="" /></td>'."\n";
echo '<td>'.$row['id_from'].'</td>'."\n";
echo '<td>'.$row['date_0'].'</td>'."\n";
echo '<td><a href="messages.php?message='.$row['id'].'">'.$row['subject'].'</a></td></tr>'."\n";
}