Access Denied\n"; echo"You do not have access to the Category Manager"; include"$page_footer"; echo"\n"; exit; } ?> MySQL Error ".mysql_errno().": ".mysql_error()."", E_USER_NOTICE); } } ?>

Manage Category List

     Show Categories for Application: $appname"; if ($num_results>$i) { echo" / "; } } ?> "Extensions", "T"=>"Themes","P"=>"Plugins"); $sql1 = "SELECT `CatType`, `CatApp` FROM `categories` WHERE `CatApp`='$application' GROUP BY `CatType` ORDER BY `CatType`"; $sql_result1 = mysql_query($sql1, $connection) or trigger_error("MySQL Error ".mysql_errno().": ".mysql_error()."", E_USER_NOTICE); while ($row = mysql_fetch_array($sql_result1)) { $type = ucwords($row["CatType"]); $application = strtolower($row["CatApp"]); $typename=$typenames["$type"]; ?> \n"; echo"\n"; echo"\n"; echo"\n"; echo"\n"; } } ?>

Name Description
$i$catname$catdesc

New Category for

Name:
Description:
Type: If other, Type:
Processing Update, please wait...\n"; $categoryid = escape_string($_POST["categoryid"]); $catname = escape_string($_POST["catname"]); $catdesc = escape_string($_POST["catdesc"]); $cattype = escape_string($_POST["cattype"]); if (checkFormKey()) { $sql = "UPDATE `categories` SET `CatName`='$catname', `CatDesc`='$catdesc', `CatType`='$cattype' WHERE `CategoryID`='$categoryid'"; $sql_result = mysql_query($sql, $connection) or trigger_error("
MySQL Error ".mysql_errno().": ".mysql_error()."
", E_USER_NOTICE); echo"Your update to $catname, has been submitted successfully...
"; } } else if ($_POST["submit"] == "Delete Category") { echo"

Processing Delete Request, please wait...

\n"; $categoryid = escape_string($_POST["categoryid"]); if (checkFormKey()) { $sql = "DELETE FROM `categories` WHERE `CategoryID`='$categoryid'"; $sql_result = mysql_query($sql, $connection) or trigger_error("
MySQL Error ".mysql_errno().": ".mysql_error()."
", E_USER_NOTICE); } echo"You've successfully deleted the category '$catname'...
"; } if (!$categoryid) { $categoryid = escape_string($_POST["categoryid"]); } // Show Edit Form $sql = "SELECT * FROM `categories` WHERE `CategoryID` = '$categoryid' LIMIT 1"; $sql_result = mysql_query($sql, $connection) or trigger_error("
MySQL Error ".mysql_errno().": ".mysql_error()."
", E_USER_NOTICE); $row = mysql_fetch_array($sql_result); $categoryid = $row["CategoryID"]; $catapp = ucwords($row["CatApp"]); $catname = $row["CatName"]; $catdesc = $row["CatDesc"]; $cattype = $row["CatType"]; ?>

Edit Category :


\n"; echo"Description:
\n"; echo"Type:
\n"; echo"\n"; ?> for ?');">

«« Return to Category Manager