Location: PHPKode > projects > phpBlogger > admin/delete.php
<?php
###############################
#delete.php       version 1.1.#
###############################
$id = (int)$_GET['id'];
$ref = (int)$_GET['ref'];
include ('header.php');
?>
<div id="headermenu">Manage</div>
<?php
if($ref == 1){
$sql = 'DELETE FROM comment WHERE commid = '.$conn->qstr($id).'';
	if($conn->Execute($sql) === false) {
		print '<br /><div id="error">error: '.$conn->ErrorMsg().'</div><br />';
	}
	echo "<div id ='information'>&nbsp;Successfully. ";
}
if($ref == 2){
$sql2 = 'DELETE FROM reviews WHERE revid = '.$conn->qstr($id).'';
	if($conn->Execute($sql2) === false) {
		print '<br /><div id="error">error: '.$conn->ErrorMsg().'</div><br />';
	}
	echo "<div id ='information'>&nbsp;Successfully. ";
}
$conn->Close();
?>
<a href="index.php">Main Config</a></div>
</div></div></div>
<?php include ('footer.php'); ?>
Return current item: phpBlogger