begin.php
1.12 KB
<?php
if(isset($_GET['topRub']) && $_GET['topRub']>0){
$objCatalogs->activeRubricTop($_GET['topRub'],$_GET['top']);
header("location:" . URL . "admin.php?action={$rule['action']}");
}
if(isset($_GET['update_activeID']) && $_GET['update_activeID']>0){
$objCatalogs->activeNull($_GET['update_activeID']);
header("location:" . URL . "admin.php?action={$rule['action']}");
}
if(isset($_POST['save'])){
$objCatalogs->trim($_POST);
if(!$objCatalogs->valid($_POST,$_FILES)){
$objCatalogs->SaveRubric($_POST,$_FILES);
header("location:" . URL . "admin.php?action={$rule['action']}");
}
}elseif(isset($_GET['updateID']) && $_GET['updateID']>0){
$objCatalogs->viewRubricOne($_GET['updateID'],$row);
}elseif(isset($_GET['deleteID']) && $_GET['deleteID']>0){
$objCatalogs->deleteRubric($_GET['deleteID']);
header("location:" . URL . "admin.php?action={$rule['action']}");
}
$RubricId = (isset($_GET['parent_rubID']) && $_GET['parent_rubID']>0) ? $_GET['parent_rubID'] : ((isset($_GET['rubID']) && $_GET['rubID']>0) ? $_GET['rubID'] : 0);
$objCatalogs->viewRubricsAll(0);
$objCatalogs->viewRubrics_begin();
$objCatalogs->displayCatalogs();
?>