本文整理汇总了PHP中zen_delete_products_attributes函数的典型用法代码示例。如果您正苦于以下问题:PHP zen_delete_products_attributes函数的具体用法?PHP zen_delete_products_attributes怎么用?PHP zen_delete_products_attributes使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了zen_delete_products_attributes函数的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: zen_redirect
}
} else {
$messageStack->add_session(ERROR_CANNOT_MOVE_CATEGORY_TO_CATEGORY_SELF . $cPath, 'error');
zen_redirect(zen_href_link(FILENAME_CATEGORIES, 'cPath=' . $cPath));
}
break;
// @@TODO where is move_product_confirm
// @@TODO where is insert_product
// @@TODO where is update_product
// attribute features
// @@TODO where is move_product_confirm
// @@TODO where is insert_product
// @@TODO where is update_product
// attribute features
case 'delete_attributes':
zen_delete_products_attributes($_GET['products_id']);
$messageStack->add_session(SUCCESS_ATTRIBUTES_DELETED . ' ID#' . $_GET['products_id'], 'success');
$action = '';
// reset products_price_sorter for searches etc.
zen_update_products_price_sorter($_GET['products_id']);
zen_redirect(zen_href_link(FILENAME_CATEGORIES, 'cPath=' . $cPath . '&pID=' . $_GET['products_id'] . (isset($_GET['page']) ? '&page=' . $_GET['page'] : '')));
break;
case 'update_attributes_sort_order':
zen_update_attributes_products_option_values_sort_order($_GET['products_id']);
$messageStack->add_session(SUCCESS_ATTRIBUTES_UPDATE . ' ID#' . $_GET['products_id'], 'success');
$action = '';
zen_redirect(zen_href_link(FILENAME_CATEGORIES, 'cPath=' . $cPath . '&pID=' . $_GET['products_id'] . (isset($_GET['page']) ? '&page=' . $_GET['page'] : '')));
break;
// attributes copy to product
// attributes copy to product
case 'update_attributes_copy_to_product':
示例2: zen_redirect
zen_redirect(zen_href_link(FILENAME_ATTRIBUTES_CONTROLLER, $_SESSION['page_info'] . '¤t_category_id=' . $_POST['current_category_id']));
}
if (isset($_POST['delete_attribute_id'])) {
$attribute_id = zen_db_prepare_input($_POST['delete_attribute_id']);
$db->Execute("delete from " . TABLE_PRODUCTS_ATTRIBUTES . "\n where products_attributes_id = '" . (int) $attribute_id . "'");
// added for DOWNLOAD_ENABLED. Always try to remove attributes, even if downloads are no longer enabled
$db->Execute("delete from " . TABLE_PRODUCTS_ATTRIBUTES_DOWNLOAD . "\n where products_attributes_id = '" . (int) $attribute_id . "'");
// reset products_price_sorter for searches etc.
zen_update_products_price_sorter($products_filter);
zen_redirect(zen_href_link(FILENAME_ATTRIBUTES_CONTROLLER, $_SESSION['page_info'] . '¤t_category_id=' . $_POST['current_category_id']));
}
break;
// delete all attributes
// delete all attributes
case 'delete_all_attributes':
zen_delete_products_attributes($_POST['products_filter']);
$messageStack->add_session(SUCCESS_ATTRIBUTES_DELETED . ' ID#' . $products_filter, 'success');
$action = '';
$products_filter = (int) $_POST['products_filter'];
// reset products_price_sorter for searches etc.
zen_update_products_price_sorter($products_filter);
zen_redirect(zen_href_link(FILENAME_ATTRIBUTES_CONTROLLER, 'products_filter=' . $products_filter . '¤t_category_id=' . $_POST['current_category_id']));
break;
case 'delete_option_name_values':
$delete_attributes_options_id = $db->Execute("select * from " . TABLE_PRODUCTS_ATTRIBUTES . " where products_id='" . $_POST['products_filter'] . "' and options_id='" . $_POST['products_options_id_all'] . "'");
while (!$delete_attributes_options_id->EOF) {
// remove any attached downloads
$remove_downloads = $db->Execute("delete from " . TABLE_PRODUCTS_ATTRIBUTES_DOWNLOAD . " where products_attributes_id= '" . $delete_attributes_options_id->fields['products_attributes_id'] . "'");
// remove all option values
$delete_attributes_options_id_values = $db->Execute("delete from " . TABLE_PRODUCTS_ATTRIBUTES . " where products_id='" . $_POST['products_filter'] . "' and options_id='" . $_POST['products_options_id_all'] . "'");
$delete_attributes_options_id->MoveNext();