hi my name is lester page and i have a problem that is displaying links to the owner of the comment. the code is working fine but the thing is the links are being displayesd whether the logged in user is the owner or not. the database i have heading and comment with the user name and the author the author is the same as the username. please help below is the code
<?php
include('includes/setting.php');
$for=mysql_query('SELECT * FROM commentsss');
while($fores=mysql_fetch_array($for)){
echo "<table width='85%' border='1' align='center'>
<tr>
<td width='126' rowspan='2'><p><strong><br><br><br><br>Username</strong>: ".$fores['username']."</p><strong><br>Email:</strong> <p>".$fores['email']."</p></td>
<td height='121' colspan='2'><h2>Title: ".$fores['heading']."</h2></td>
<td width='126' rowspan='2'><h4><br><br><br><br><br><a href=\"editscommsss.php?post_id=
".$fores['post_id']."&heading=".$fores['heading']."\">Edit</a> | <a href=\"deletecommsss.php?post_id=
".$fores['post_id']."&heading=".$fores['heading']."\">Delete</a></h4></td>
</tr>
<tr>
<td height='136' colspan='2'><strong>Comment:</strong><p>".$fores['comment']."</p></td>
</tr>
</table>";
}
?>
thank you in advance