[ic] potential problem with shipping tag implementation on Foundation checkout page

Jeff Dafoe interchange-users@icdevgroup.org
Fri Jan 24 12:43:00 2003


    I have noticed what I think may be a small issue with the way most
people will implement the shipping tag and the way it is implemented on the
Foundation checkout page.  I don't recall having seen this mentioned in here
before.  The standard foundation checkout page uses [shipping] to display
the shipping amount.  The shipping tag knows which shipping mode to display
the price for by using this logic (from docs):

[value mv_handling] if handling=1 or [value mv_shipmode] or 'default'

    The issue occurs when someone changes their country on the checkout
page.  At that point, the page reloads.  The select box for the shipmodes is
now potentially loaded with a new set of values (depending on the shipping
modes you offer).  If the cost of the first shipping mode now shown in the
select box is not the same as the cost of the first shipping mode that was
shown previously, the shipping amount shown at the top of the page will be
wrong.  This is because mv_shipmode didn't change when the form was
reposted, so the shipping tag is still using the previous value for the
calculation.


Jeff