예제 #1
0
function deleteBranch($pid)
{
    $s_sql = "Select item_id from tree where item_parent_id={$pid}";
    $res = mysql_query($s_sql);
    if ($res) {
        while ($row = mysql_fetch_array($res)) {
            deleteBranch($row['item_id']);
            deleteSingleNode($row['item_id']);
        }
    }
}
예제 #2
0
function deleteBranch($pid)
{
    $s_sql = "Select item_id,item_order from samples_tree where item_parent_id={$pid}  and GUID='" . $_SESSION["id"] . "'";
    $res = mysql_query($s_sql);
    if ($res) {
        while ($row = mysql_fetch_array($res)) {
            deleteBranch($row['item_id']);
            deleteSingleNode($row['item_id']);
        }
    }
}