通达OA2007SE源代码
非常好的
源代码在线查看: delete.php
function tree_delete ($SORT_ID)
{
global $connection;
$query = ((''.'delete from FILE_SORT where SORT_ID=').$SORT_ID);
exequery ($connection, $query);
$query = ((''.'select * from FILE_CONTENT where SORT_ID=').$SORT_ID);
$cursor = exequery ($connection, $query);
while ($ROW = mysql_fetch_array ($cursor))
{
$ATTACHMENT_ID = $ROW['ATTACHMENT_ID'];
$ATTACHMENT_NAME = $ROW['ATTACHMENT_NAME'];
if (($ATTACHMENT_NAME != ''))
{
delete_attach ($ATTACHMENT_ID, $ATTACHMENT_NAME);
continue;
}
}
$query = ((''.'delete from FILE_CONTENT where SORT_ID=').$SORT_ID);
exequery ($connection, $query);
$query = ((''.'select * from FILE_SORT where SORT_PARENT=').$SORT_ID);
$cursor = exequery ($connection, $query);
while ($ROW = mysql_fetch_array ($cursor))
{
$SORT_ID = $ROW['SORT_ID'];
tree_delete ($SORT_ID);
}
return null;
}
include_once 'inc/auth.php';
include_once 'inc/utility_all.php';
echo '
';
tree_delete ($SORT_ID);
header ('location: index.php');
echo '
';
?>