|
Posted by JJ Mac on 07/25/06 22:30
Ok i need some help with creating a dynamic drop down list. Or should i
say a list getting info from a mysql database. This is the part of the
code i now use to list out the things out of the database which i would
like to put in a list and have two buttons, one would be to edit the
item selected in the list(item would link to a whole file listing
everything stored in that row in the database and there for me to
edit), and another to delete that selection or i mean to delet the
whole row. If anybody could help me with this it would be great. Thnx
in advance.
$result = mysql_query("SELECT * FROM profile",$db);
while ($myrow = mysql_fetch_array($result)) {
printf("<a href=\"%s?id=%s\">%s %s</a> \n", $PHP_SELF,
$myrow["id"], $myrow["name"], $myrow["rank"]);
printf("<a href=\"%s?id=%s&delete=yes\">(DELETE)</a><br>",
$PHP_SELF, $myrow["id"]);
}
}
Navigation:
[Reply to this message]
|