Prev | Current Page 438 | Next

Emilian Balanescu and Cristian Darie

"Beginning PHP and MySQL E-Commerce: From Novice to Professional, Second Edition"

..
if (isset ($_POST['RemoveAttributeValue']))
{
$target_attribute_value_id = $_POST['TargetAttributeValueIdRemove'];
Catalog::RemoveProductAttributeValue($this->_mProductId,
$target_attribute_value_id);
}
// If moving the product to another category ...
if (isset ($_POST['Move']))
{
$target_category_id = $_POST['TargetCategoryIdMove'];
Catalog::MoveProductToCategory($this->_mProductId,
$this->_mCategoryId, $target_category_id);
header('Location: ' .
htmlspecialchars_decode(
Link::ToProductAdmin($this->_mDepartmentId,
$target_category_id,
$this->_mProductId)));
exit();
}
CHAPTER 11 ?–  CATALOG ADMINISTRATION: PRODUCTS AND ATTRIBUTES 337
// Get product info
$this->mProduct = Catalog::GetProductInfo($this->_mProductId);
$product_categories = Catalog::GetCategoriesForProduct($this->_mProductId);
$product_attributes =
Catalog::GetProductAttributes($this->_mProductId);
for ($i = 0; $i < count($product_attributes); $i++)
$this->mProductAttributes[$product_attributes[$i]['attribute_value_id']] =
$product_attributes[$i]['attribute_name'] . ': ' .
$product_attributes[$i]['attribute_value'];
$catalog_attributes =
Catalog::GetAttributesNotAssignedToProduct($this->_mProductId);
for ($i = 0; $i < count($catalog_attributes); $i++)
$this->mCatalogAttributes[$catalog_attributes[$i]['attribute_value_id']] =
$catalog_attributes[$i]['attribute_name'] .


Pages:
426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450
ABC kompresory parasole reklamowe sypialnia 2 1