I was wondering if you anyone could help me again with something!!
I've finished my table view page, and its all working nicely!
But, I would like to have a delete (hyperlink??) function at the end of each row to remove a user and all his data and information stored in the database etc..
this is what my testview.php script currently looks like:
<?php
$conn = mysql_connect("localhost","root","") or die("Could Not Connect To The Database");
mysql_select_db("aziz",$conn) or die("Could Not Select The Database");
$result=mysql_query("SELECT user_id,az_firstname,az_surname,username FROM azizpassword ORDER BY user_id;");
$i=0;
while( $row=mysql_fetch_array($result) )
{
if($i>0)
{
echo "<tr valign=top>";
echo "<td bgcolor=#93B0B4 colspan=4><img src=img/blank.gif wuser_idth=1 height=1></td>";
echo "</tr>";
}
echo "<tr valign=center>";
echo "<td width=100 class=table><b>".$row['user_id']."</b></td>";
echo "<td width=100 class=table><a href=\"view.php?id=".$row['user_id']."\">".$row['az_surname']."</a></td>";
echo "<td width=100 class=table>".$row['az_firstname']." </td>";
echo "<td width=100 class=table><i>".$row['username']."</i> </td>";
echo "<td class=table></td>";
echo "</tr>";
$i++;
}
echo "<tr valign=bottom>";
echo "<td bgcolor=#93B0B4 colspan=6 height=8></td>";
echo "</tr>";
?>
its got the table data there, and this all works fine, but, i would like to install a delete function hyperlink at the end of each row that will delete all the information of that chosen user from the database, ive tried a few methods but they just dont work.
Any idea's anyone would so great??
thanks a lot in advance I really appreciate it!!