1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
<?php //require 'db_connect.php'; require 'check_login.php'; if ($logged_in <> 1) { header('Location: login.php'); return; } else { ?> <? require("configure.php"); ?> <? $catid = $_GET["catid"]; $parentid = $_GET["parentid"];
$sql = "DELETE FROM categories WHERE catid=". $catid ." "; //if ($parentid <> "") //$sql = "update categories set parentid='' where catid='". $catid ."' ";
mysql_query($sql); mysql_close($dbh);
//header("Location: categoriesindex.php?pid=$catid&msg=Update Successful"); header("Location: categoriesindex.php?pid=$parentid&msg=Update Successful"); ?>
<?php } ?>
|