Page 1 of 2 12 LastLast
Results 1 to 10 of 96

Hybrid View

  1. #1
    Join Date
    Sep 2007
    Location
    Manchester, England
    Posts
    168
    Plugin Contributions
    0

    Default Re: Shipping Rates in Cart [support thread]

    Quote Originally Posted by Steven300 View Post
    I haven't tested this yet and it may not work for downloadable or virtual products.

    In includes/templates/your_template/templates/tpl_shopping_cart_default.php

    Find:
    PHP Code:
    $sric_total $cartSricTotal $sric_shipping_simple
    Directly below it, add these two lines:
    PHP Code:
    $vat = ($sric_total 100) * 15;
    $sric_total $sric_total $vat
    Hey steven, thanks for the reply.

    I was considering heading that direction (manually working out the VAT deduction) but it causes some issues.

    If I implement that code, the total displayed on the mod differs from the total displayed in the cart, by a penny.

    For example, the order I'm testing right now, the mod displays it like - Total: £35.08, but the Zen shopping cart displays it like Total: £35.07

    I'm guessing ZC uses a different method of rounding up the sum.

    Thanks though!

  2. #2
    Join Date
    Sep 2007
    Location
    Manchester, England
    Posts
    168
    Plugin Contributions
    0

    Default Re: Shipping Rates in Cart [support thread]

    RIGHT, I've sorted it.

    It turns out that PHP5 (which we run locally) rounds up numbers slightly different to PHP4 (which we run on our shared servers).

    So essentially, your way worked fine, but only in PHP4. In PHP5, it misses a penny out.

    Thanks for your help, this has been an immensely helpful module

  3. #3
    Join Date
    Mar 2009
    Posts
    57
    Plugin Contributions
    0

    Default Re: Shipping Rates in Cart [support thread]

    nice little mode, pretty easay to install however I am getting the following error at the bottom of the cart page (using 1.3.8a zen)

    Fatal error: Cannot redeclare class shipping in /store/includes/classes/shipping.php on line 178

    any thoughts on fixing this?

    thanks

    john

  4. #4
    Join Date
    Mar 2009
    Posts
    57
    Plugin Contributions
    0

    Default Re: Shipping Rates in Cart [support thread]

    ok well I solved it by setting the shipping estimator display settings to 0.

  5. #5
    Join Date
    Jan 2008
    Posts
    1,700
    Plugin Contributions
    6

    Default Re: Shipping Rates in Cart [support thread]

    Yes, as you found out, the contribution uses the same code as the estimator, so if both pieces of code exist at the same time, an error will likely occur. Glad you discovered this and got it sorted

  6. #6
    Join Date
    Mar 2009
    Posts
    57
    Plugin Contributions
    0

    Default Re: Shipping Rates in Cart [support thread]

    ok i've got one other issue. It seems that when I add an item that has an one time extra fee (which is an extra shipping fee) but no shipping otherwise with a product that should be charged for shipping, the shipping rate goes to zero but it should be still charged for the one item.

    I supposed this could be an inherent flaw with the cart shipping itself, and not the module but i've just noticed it now so wondering in anyone has any thoughts.

    thanks

  7. #7
    Join Date
    Feb 2007
    Posts
    1,704
    Plugin Contributions
    0

    Default Re: Shipping Rates in Cart [support thread]

    does the shipping estimate show one time charges?

  8. #8
    Join Date
    Jan 2008
    Posts
    1,700
    Plugin Contributions
    6

    Default Re: Shipping Rates in Cart [support thread]

    I'm not sure. Are you referring to the contribution or the core estimator or both?

  9. #9
    Join Date
    Jun 2009
    Location
    United States
    Posts
    4
    Plugin Contributions
    0

    cart error Re: Shipping Rates in Cart [support thread]

    Hi,

    I've read all the posts in this thread and can't seem to find the answer.

    I've installed the Shipping Rates in Cart contribution on a clean install of Zen Cart v. 1.3.8a (no modifications) and got a bunch of code displaying on the shopping cart page (see pic). I am running Zen Cart on a local server (Wamp)and unfortunately don't have a link to the live website. Any ideas what might be causing this?

    The code displayed on the shopping cart page is coming from includes/templates/template_default/templates/tpl_shopping_cart_default.php The code shown is:
    PHP Code:
    format(zen_add_tax($quotes[$i]['methods'][0]['cost'], $quotes[$i]['tax'])); //Without currency symbol $sric_shipping_simple = $currencies->format(zen_add_tax($quotes[$i]['methods'][0]['cost'], $quotes[$i]['tax'])); } } } //Display currency code in cart if (SRIC_DISPLAY_CURRENCY_CODE == 'Yes, before price') { $currency_code_opt_before = $_SESSION['currency'] . " "; $currency_code_opt_after = ''; $currency_code_opt_total_before = $_SESSION['currency'] . " "; $currency_code_opt_total_after = ''; } else if (SRIC_DISPLAY_CURRENCY_CODE == 'Yes, after price') { $currency_code_opt_before = ''; $currency_code_opt_after = " " . $_SESSION['currency']; $currency_code_opt_total_before = ''; $currency_code_opt_total_after = " " . $_SESSION['currency']; } else if (SRIC_DISPLAY_CURRENCY_CODE == 'Yes, before price, for total only') { $currency_code_opt_before = ''; $currency_code_opt_after = ''; $currency_code_opt_total_before = $_SESSION['currency'] . " "; $currency_code_opt_total_after = ''; } else if (SRIC_DISPLAY_CURRENCY_CODE == 'Yes, after price, for total only') { $currency_code_opt_before = ''; $currency_code_opt_after = ''; $currency_code_opt_total_before = ''; $currency_code_opt_total_after = " " . $_SESSION['currency']; } else { $currency_code_opt_before = ''; $currency_code_opt_after = ''; $currency_code_opt_total_before = ''; $currency_code_opt_total_after = ''; } //Calculate total $cartSricTotal = preg_replace ( '#\D*?(\d+(\.\d+)?)\D*#', '$1', $cartShowTotal ); $sric_shipping_simple = preg_replace ( '#\D*?(\d+(\.\d+)?)\D*#', '$1', $sric_shipping_simple ); $sric_total = $cartSricTotal + $sric_shipping_simple; $sric_total = number_format($sric_total,2); //If no shipping charge if ( ($sric_shipping == '') && (SRIC_NO_SHIP == 'Display zero shipping price') ) { $sric_shipping = $currency_symbol . "0.00"; ?> 
    Thanks in advance for any ideas/solutions
    Attached Images Attached Images  

  10. #10
    Join Date
    Jan 2008
    Posts
    1,700
    Plugin Contributions
    6

    Default Re: Shipping Rates in Cart [support thread]

    I just tested the mod on my WAMP install and I get the exact same problem.

    However it works absolutely fine when online.

    Not yet sure why that is.

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. Add Shipping Telephone Support Thread
    By JTheed in forum Addon Admin Tools
    Replies: 31
    Last Post: 4 Sep 2018, 11:14 AM
  2. Multiple Zone Rates Support Thread
    By totalsam in forum Addon Shipping Modules
    Replies: 54
    Last Post: 24 Feb 2015, 03:34 PM
  3. Replies: 29
    Last Post: 24 Sep 2014, 09:59 PM
  4. Empty Cart Manager [support thread]
    By Steven300 in forum All Other Contributions/Addons
    Replies: 49
    Last Post: 26 May 2010, 10:26 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg