} } } elseif (isset($_GET['delete_pure_image']) && $_GET['delete_pure_image'] != '') { $pid = tep_db_prepare_input($_GET['products_id']); $pq = tep_db_query('SELECT products_pure_image FROM products WHERE products_id=' . $pid); $p = tep_db_fetch_array($pq); $delete_file = $uploaddir . $p['products_pure_image']; if (file_exists($delete_file)) { unlink($delete_file); tep_db_perform('products', array('products_pure_image' => ''), 'update', 'products_id=' . $pid); } } //SUBMIT ACTION $class_pa->processAction(); //HANDLE POST/GET ACTION THAT RELATED TO ARTICLES $class_pm->drawAttributesPostAction(); if (isset($_POST['me_action'])) { $pid = tep_db_prepare_input($_POST['products_id']); if ($_POST['me_action'] == 'SAVECOGSMANUAL') { $cogs_value = tep_db_prepare_input($_POST['cogs']); $obj_product = new Product($pid); $obj_product->saveCOGSManual($cogs_value); echo utf8_encode($obj_product->getProductCOGSObject()->drawDetailTable()); exit; } elseif ($_POST['me_action'] == 'FINALIZETRADEBYTE') { //Update table 'products' $sda = array(); $sda['products_gender'] = tep_db_prepare_input($_POST['products_gender']); $sda['products_agegroup'] = tep_db_prepare_input($_POST['products_agegroup']); tep_db_perform('products', $sda, 'update', "products_id={$pid}"); //Update table 'jng_sp_catalog'