function recursiveDelete($id) {
$result=mysql_query("SELECT * FROM vb_users WHERE parent_uid = '$id'");
if (mysql_num_rows($result)>0) {
while($current=mysql_fetch_array($result)) {
recursiveDelete($current['id']);
}
}
echo $id."<br>";
// mysql_query("DELETE FROM cc_reseller WHERE id='$id'") or die("some thing error 1");
}
recursiveDelete($_GET['id']);
$result=mysql_query("SELECT * FROM vb_users WHERE parent_uid = '$id'");
if (mysql_num_rows($result)>0) {
while($current=mysql_fetch_array($result)) {
recursiveDelete($current['id']);
}
}
echo $id."<br>";
// mysql_query("DELETE FROM cc_reseller WHERE id='$id'") or die("some thing error 1");
}
recursiveDelete($_GET['id']);
No comments:
Post a Comment