Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

GlebeCS

Archived
  • Posts

    28
  • Joined

  • Last visited

Profile Information

  • Real Name
    Andy Kemp

GlebeCS's Achievements

  1. Hello, I have a problem with strange characters produced in my shopping_cart.php that seem to be coming from this contrib (I have the latest version installed) I have detailed the problem (along with the code) , HERE Could anyone advise please? Thanks Andy
  2. I have just noticed that the tax is displaye dincorrectly when I look at order history too, when placing the order all looks fine but once complete and revisisted it defaults to the tax on the non-discounted total, help please
  3. OK, I am getting there now, I have chenged the code as follows and it now displays the correct VAT/TAX on the checkout etc, but reverts to the incorrect tax on the order details page within admin, and also on an invoice if ($cart->count_contents() > 0) { if ((isset($_POST['coupon_code'])) and ($_POST['coupon_code'] != '')) { switch (strtolower($_POST['coupon_code'])) { case '5percentoff' : $new_discount = $cart->show_total() * 0.05; $discount_percentage = 0.05; $easy_discount->reset();$easy_discount->set('COUPON1','5% Coupon Discount', $new_discount); break; case '10percentoff' : $new_discount = $cart->show_total() * 0.10; $discount_percentage = 0.1; $easy_discount->reset();$easy_discount->set('COUPON2','10% Coupon Discount', $new_discount); break; case '20percentoff' : $new_discount = $cart->show_total() * 0.20; $discount_percentage = 0.2; $easy_discount->reset();$easy_discount->set('COUPON3','20% Coupon Discount', $new_discount); break; } } } else { $easy_discount->reset(); } Anyone help me get past this final hurdle? Thank you, Andy
  4. Hello, I have read through this thread and have this excellent contrib installed and working. I have the same problem with tax (VAT) that maniac101 described, the VAT shown is calculated from the total before discount. I have modified the modules\orders_total\ot_easy_discount.php using maniac101's instructions but cannot work out what I need in application_top , my discount code is as follows: if ($cart->count_contents() > 0) { if ((isset($_POST['coupon_code'])) and ($_POST['coupon_code'] != '')) { switch (strtolower($_POST['coupon_code'])) { case '5percentoff' : $new_discount = $cart->show_total() * 0.05; $easy_discount->reset();$easy_discount->set('COUPON1','5% Coupon Discount', $new_discount); break; case '10percentoff' : $new_discount = $cart->show_total() * 0.10; $easy_discount->reset();$easy_discount->set('COUPON2','10% Coupon Discount', $new_discount); break; case '20percentoff' : $new_discount = $cart->show_total() * 0.20; $easy_discount->reset();$easy_discount->set('COUPON3','20% Coupon Discount', $new_discount); break; } } } else { $easy_discount->reset(); } I understand that I need to set $discount_percentage somehow but cannot work out how. Any help much appreciated. P.S. I inserted the extra $easy_discount->reset(); after each code as this prevents people using more than one code per order Andy
  5. Anybody please? I would really like to get this contribution working
  6. OK, I have now modified the code as follows: <script language="JavaScript" <script type="text/javascript"> _editor_url = "/catalog/admin/htmlarea/"; _editor_lang = "en"; </script> <script language="JavaScript" <script type="text/javascript" src="/htmlarea/htmlarea.js"></script> <script language="JavaScript" <script type="text/javascript" defer="1"> HTMLArea.replaceAll(); </script> I am at least getting something different, when loading the categories.php in the admin all loads as normal (still no HTMLarea) but I have a script error "HTMLarea not defined" on line 151 Line 151 is: $product_categories_query = tep_db_query("select count(*) as total from " . TABLE_PRODUCTS_TO_CATEGORIES . " where products_id = '" . (int)$product_id . "'"); Does this give anyone any clues? Cheers Andy
  7. I am still plugging away trying to get this sorted, I am wondering if I am inserting the code in the right place in the categories.php file, I know nothing about php code but it looks in my editor that scripts have a grey background to highlight them, what I am typing has white background, or some places I put it the 1st part i.e. <script type="text/javascript"> _editor_url = "/htmlarea/"; _editor_lang = "en"; </script> has a grey background but the other 2 lines are white still..... looks odd Andy
  8. Hello All, I have been trying to get the HTMLarea 3 contribution to work on my oscommerce, I downloaded and copied the entire HTMLarea folder into my admin folder, then made a "htmlarea" folder in catalogue/images and set to CHMOD 777 as required. Editing categories.php I have added this: <script type="text/javascript"> _editor_url = "/htmlarea/"; _editor_lang = "en"; </script> <script type="text/javascript" src="/htmlarea/htmlarea.js"></script> <script type="text/javascript" defer="1"> HTMLArea.replaceAll(); </script> I have also tried _editor_url = "admin/htmlarea/"; It simply does not appear when I try to edit products etc, what am I doing wrong? Andy
×
×
  • Create New...