_:n23fcd63c62e9415c8f29b83dd37ab358xb31
<http://schema.org/text>
"@@14steve14 Hi Steve,\n \nI have tried this install as mentioned and can not get the catalog/admin/categories.php to work no matter how I do it with or without the optional javascript as stated at the end of the files edit.\n \n \nI have also noticed a couple of lines mentioned in the instructions which do not exist so maybe this is where I'm going wrong??\n \n \n \nI have included my categories.php for any to look at and hopefully point me in the right direction.\n \n \nThanks in advance.\n \n1.   &lt;script language=\"javascript\" src=\"includes/general.js\"&gt;&lt;/script&gt;\n \n2. // BOF Separate Pricing per Customer\n\t    if (is_array($value)) {\n\t\t  while (list($k, $v) = each($value)) {\n\t\t  echo tep_draw_hidden_field($key . '[' . $k . ']', htmlspecialchars(stripslashes($v)));\n\t\t  }\n\t    } else {\n// EOF Separate Pricing per Customer\n \n \n \n \n\n\n&lt;?php\n/*\n $Id$\n adapted for Separate Pricing Per Customer v4.2 2007/08/05, QPBPP for SPPC v2.0 2008/11/23\n osCommerce, Open Source E-Commerce Solutions\n http://www.oscommerce.com\n Copyright (c) 2010 osCommerce\n Released under the GNU General Public License\n*/\n require('includes/application_top.php');\n require(DIR_WS_CLASSES . 'currencies.php');\n $currencies = new currencies();\n // BOF QPBPP for SPPC\n// include the admin version of price formatter for the price breaks contribution\n require(DIR_WS_CLASSES . 'PriceFormatterAdmin.php');\n $pf = new PriceFormatter;\n// EOF QPBPP for SPPC\n $action = (isset($HTTP_GET_VARS['action']) ? $HTTP_GET_VARS['action'] : '');\n if (tep_not_null($action)) {\n   switch ($action) {\n  case 'setflag':\n    if ( ($HTTP_GET_VARS['flag'] == '0') || ($HTTP_GET_VARS['flag'] == '1') ) {\n\t  if (isset($HTTP_GET_VARS['pID'])) {\n\t    tep_set_product_status($HTTP_GET_VARS['pID'], $HTTP_GET_VARS['flag']);\n\t  }\n\t  if (USE_CACHE == 'true') {\n\t    tep_reset_cache_block('categories');\n\t    tep_reset_cache_block('also_purchased');\n\t  }\n    }\n    tep_redirect(tep_href_link(FILENAME_CATEGORIES, 'cPath=' . $HTTP_GET_VARS['cPath'] . '&amp;pID=' . $HTTP_GET_VARS['pID']));\n    break;\n  case 'insert_category':\n  case 'update_category':\n    if (isset($HTTP_POST_VARS['categories_id'])) $categories_id = tep_db_prepare_input($HTTP_POST_VARS['categories_id']);\n    $sort_order = tep_db_prepare_input($HTTP_POST_VARS['sort_order']);\n    $sql_data_array = array('sort_order' =&gt; (int)$sort_order);\n    if ($action == 'insert_category') {\n\t  $insert_sql_data = array('parent_id' =&gt; $current_category_id,\n\t\t\t\t\t\t\t   'date_added' =&gt; 'now()');\n\t  $sql_data_array = array_merge($sql_data_array, $insert_sql_data);\n\t  tep_db_perform(TABLE_CATEGORIES, $sql_data_array);\n\t  $categories_id = tep_db_insert_id();\n    } elseif ($action == 'update_category') {\n\t  $update_sql_data = array('last_modified' =&gt; 'now()');\n\t  $sql_data_array = array_merge($sql_data_array, $update_sql_data);\n\t  tep_db_perform(TABLE_CATEGORIES, $sql_data_array, 'update', \"categories_id = '\" . (int)$categories_id . \"'\");\n    }\n    $languages = tep_get_languages();\n    for ($i=0, $n=sizeof($languages); $i&lt;$n; $i++) {\n\t  $categories_name_array = $HTTP_POST_VARS['categories_name'];\n\t  $language_id = $languages[$i]['id'];\n\t  $sql_data_array = array('categories_name' =&gt; tep_db_prepare_input($categories_name_array[$language_id]));\n\t  if ($action == 'insert_category') {\n\t    $insert_sql_data = array('categories_id' =&gt; $categories_id,\n\t\t\t\t\t\t\t\t 'language_id' =&gt; $languages[$i]['id']);\n\t    $sql_data_array = array_merge($sql_data_array, $insert_sql_data);\n\t    tep_db_perform(TABLE_CATEGORIES_DESCRIPTION, $sql_data_array);\n\t  } elseif ($action == 'update_category') {\n\t    tep_db_perform(TABLE_CATEGORIES_DESCRIPTION, $sql_data_array, 'update', \"categories_id = '\" . (int)$categories_id . \"' and language_id = '\" . (int)$languages[$i]['id'] . \"'\");\n\t  }\n    }\n    $categories_image = new upload('categories_image');\n    $categories_image-&gt;set_destination(DIR_FS_CATALOG_IMAGES);\n    if ($categories_image-&gt;parse() &amp;&amp; $categories_image-&gt;save()) {\n\t  tep_db_query(\"update \" . TABLE_CATEGORIES . \" set categories_image = '\" . tep_db_input($categories_image-&gt;filename) . \"' where categories_id = '\" . (int)$categories_id . \"'\");\n    }\n    if (USE_CACHE == 'true') {\n\t  tep_reset_cache_block('categories');\n\t  tep_reset_cache_block('also_purchased');\n    }\n    tep_redirect(tep_href_link(FILENAME_CATEGORIES, 'cPath=' . $cPath . '&amp;cID=' . $categories_id));\n    break;\n  case 'delete_category_confirm':\n\n\n\n"
<https://forums.oscommerce.com/topic/53436-seperate-pricing-per-customer-v35/?page=235&tab=comments#comment-1620780>