KemoSabe Posted August 19, 2006 Share Posted August 19, 2006 (edited) after installing this mod i stumbled across an error message. something that i was hopeing not to encounter. Shipping Zones Fatal error: Call to undefined function: tep_get_cat_zone_name() in .../catalog/admin/shipping_zones.php on line 233 i can't edit, delete, insert or view details of an item in "Shipping Zones" located in "Locations / Taxes". is it a SQL problem? Edited August 19, 2006 by KemoSabe Quote Link to comment Share on other sites More sharing options...
KemoSabe Posted August 19, 2006 Author Share Posted August 19, 2006 <?php echo HEADING_TITLE; if (isset($HTTP_GET_VARS['zID']) && tep_not_null($HTTP_GET_VARS['zID']) ) echo ' » ' . tep_get_cat_zone_name($HTTP_GET_VARS['zID']); ?> by deleting this code from line 276 i seem to have got it working. ??? is this a bad idea? Quote Link to comment Share on other sites More sharing options...
Guest Posted August 19, 2006 Share Posted August 19, 2006 yes it is, It is missing from the documentation. Item 3 should read: //-MS Active Shipping Added function tep_cfg_pull_down_active_zones($zone_id, $key = '') { $name = (($key) ? 'configuration[' . $key . ']' : 'configuration_value'); $zone_array = array(array('id' => '0', 'text' => TEXT_NONE)); $zone_query = tep_db_query("select cat_zone_id, cat_zone_name from " . TABLE_CAT_ZONES . " order by cat_zone_name"); while ($zone = tep_db_fetch_array($zone_query)) { $zone_array[] = array('id' => $zone['cat_zone_id'], 'text' => $zone['cat_zone_name']); } return tep_draw_pull_down_menu($name, $zone_array, $zone_id); } function tep_get_active_zone_title($zone_id) { if ($zone_id == '0') { return TEXT_NONE; } else { $zone_query = tep_db_query("select cat_zone_name from " . TABLE_CAT_ZONES . " where cat_zone_id = '" . (int)$zone_id . "'"); $zone = tep_db_fetch_array($zone_query); return $zone['cat_zone_name']; } } function tep_get_cat_zone_name($cat_zone_id, $default_zone='Unknown Zone') { $zone_query = tep_db_query("select cat_zone_name from " . TABLE_CAT_ZONES . " where cat_zone_id = '" . (int)$cat_zone_id . "'"); if (tep_db_num_rows($zone_query)) { $zone = tep_db_fetch_array($zone_query); return $zone['cat_zone_name']; } else { return $default_zone; } } //-MS Active Shipping Added EOM I will make a note on the support thread http://www.oscommerce.com/forums/index.php?showtopic=219998 and update it with the next version Quote Link to comment Share on other sites More sharing options...
KemoSabe Posted August 19, 2006 Author Share Posted August 19, 2006 yes it is, It is missing from the documentation. Item 3 should read: //-MS Active Shipping Added function tep_cfg_pull_down_active_zones($zone_id, $key = '') { $name = (($key) ? 'configuration[' . $key . ']' : 'configuration_value'); $zone_array = array(array('id' => '0', 'text' => TEXT_NONE)); $zone_query = tep_db_query("select cat_zone_id, cat_zone_name from " . TABLE_CAT_ZONES . " order by cat_zone_name"); while ($zone = tep_db_fetch_array($zone_query)) { $zone_array[] = array('id' => $zone['cat_zone_id'], 'text' => $zone['cat_zone_name']); } return tep_draw_pull_down_menu($name, $zone_array, $zone_id); } function tep_get_active_zone_title($zone_id) { if ($zone_id == '0') { return TEXT_NONE; } else { $zone_query = tep_db_query("select cat_zone_name from " . TABLE_CAT_ZONES . " where cat_zone_id = '" . (int)$zone_id . "'"); $zone = tep_db_fetch_array($zone_query); return $zone['cat_zone_name']; } } function tep_get_cat_zone_name($cat_zone_id, $default_zone='Unknown Zone') { $zone_query = tep_db_query("select cat_zone_name from " . TABLE_CAT_ZONES . " where cat_zone_id = '" . (int)$cat_zone_id . "'"); if (tep_db_num_rows($zone_query)) { $zone = tep_db_fetch_array($zone_query); return $zone['cat_zone_name']; } else { return $default_zone; } } //-MS Active Shipping Added EOM I will make a note on the support thread http://www.oscommerce.com/forums/index.php?showtopic=219998 and update it with the next version Thank you so much. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.