Esempio n. 1
0
            }
        }
        header("Location: ?open=products-brand&id={$brand_id}&action={$action}");
        exit;
    } elseif ($_POST['me_action'] == 'DELETEBRAND') {
        if ($id > 0) {
            if ($class_pb->delete($id) === false) {
                echo 'FAILED';
            } else {
                echo 'OK';
            }
        }
        exit;
    } elseif ($_POST['me_action'] == 'KILLBRAND') {
        $brand_id = $_POST['brand_id'];
        $class_pb->killBrand($brand_id, $session_userinfo['username'], true);
        exit;
    }
}
$is_deleted = false;
if ($id != '') {
    $brand = $class_pb->retrieveDetail($id);
    if (is_array($brand)) {
        $brand_id = $brand['products_brand_id'];
        $active_status = $brand['active_status'] == '1' ? 'checked="checked"' : '';
        $is_deleted = $brand['is_deleted'] == 1;
        $brand_name = $brand['brand_name'];
        $brand_desc = $brand['brand_description'];
        $seo_text = $brand['seo_text'];
        $brand_desc_preview = '<div style="width:500px;">';
        $brand_desc_preview .= '<h3>Brand Description Web Preview</h3>';