Guest Posted July 30, 2008 Share Posted July 30, 2008 when i add a special price to something I get an error and it makes the product price $0.00 here is the error Warning: Missing argument 3 for currencies::display_price(), called in /home/content/t/i/n/tinygiants/html/product_info.php on line 84 and defined in /home/content/t/i/n/tinygiants/html/includes/classes/currencies.php on line 72 Here is Productinfo.php Line 81-92 Line in error In RED tep_db_query("update " . TABLE_PRODUCTS_DESCRIPTION . " set products_viewed = products_viewed+1 where products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and language_id = '" . (int)$languages_id . "'"); if ($new_price = tep_get_products_special_price($product_info['products_id'])) { $products_price = '<s>' . $currencies->display_price($product_info['products_id'], $product_info['products_price'], tep_get_tax_rate($product_info['products_tax_class_id'])) . '</s> <span class="productSpecialPrice">' . $currencies->display_price($new_price, tep_get_tax_rate($product_info['products_tax_class_id'])) . '</span>'; } else { $products_price = $currencies->display_price($product_info['products_id'], $product_info['products_price'], tep_get_tax_rate($product_info['products_tax_class_id'])); } if (tep_not_null($product_info['products_model'])) { $products_name = $product_info['products_name'] . '<br><span class="smallText">[' . $product_info['products_model'] . ']</span>'; } else { $products_name = $product_info['products_name']; Here is Currencies line 65-85 } function get_decimal_places($code) { return $this->currencies[$code]['decimal_places']; } //TotalB2B start function display_price($products_id, $products_price, $products_tax, $quantity = 1) { global $customer_id; $query_price_to_guest = tep_db_query("select configuration_value from " . TABLE_CONFIGURATION . " WHERE configuration_key = 'ALLOW_GUEST_TO_SEE_PRICES'"); $query_price_to_guest_result = tep_db_fetch_array($query_price_to_guest); if (($query_price_to_guest_result['configuration_value']=='true') && !(tep_session_is_registered('customer_id'))) { $query_guest_discount = tep_db_query("select configuration_value from " . TABLE_CONFIGURATION . " WHERE configuration_key = 'GUEST_DISCOUNT'"); $query_guest_discount_result = tep_db_fetch_array($query_guest_discount); $customer_discount = $query_guest_discount_result['configuration_value']; if ($customer_discount >= 0) { I know this is probably a contribution question .. but there is no support there.. no one in the thread after a month ... I think this is just a syntax or some order error... lmk if you have any suggestions! Thanks! Link to comment Share on other sites More sharing options...
satish Posted July 30, 2008 Share Posted July 30, 2008 $currencies->display_price($product_info['products_id'], $product_info['products_price'], tep_get_tax_rate($product_info['products_tax_class_id'])) from error it appears that arg 3 that is tep_get_tax_rate($product_info['products_tax_class_id'] is not returning any value. For testing replace it with say 1 and test if it works then You need to dig in. Satish Ask/Skype for Free osCommerce value addon/SEO suggestion tips for your site. Check My About US For who am I and what My company does. Link to comment Share on other sites More sharing options...
Guest Posted July 30, 2008 Share Posted July 30, 2008 replace what with 1? Link to comment Share on other sites More sharing options...
satish Posted July 30, 2008 Share Posted July 30, 2008 $currencies->display_price($product_info['products_id'], $product_info['products_price'], tep_get_tax_rate($product_info['products_tax_class_id'])) to $currencies->display_price($product_info['products_id'], $product_info['products_price'], 1) Ask/Skype for Free osCommerce value addon/SEO suggestion tips for your site. Check My About US For who am I and what My company does. Link to comment Share on other sites More sharing options...
Guest Posted July 30, 2008 Share Posted July 30, 2008 same error Link to comment Share on other sites More sharing options...
satish Posted July 31, 2008 Share Posted July 31, 2008 Do echo the three values seperately and post here. Satish Ask/Skype for Free osCommerce value addon/SEO suggestion tips for your site. Check My About US For who am I and what My company does. Link to comment Share on other sites More sharing options...
Guest Posted July 31, 2008 Share Posted July 31, 2008 i'm sorry .. you'll have to explain what that means i have very basic skills .. normally its a trial and error thing :-P Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.