[ic] Country variable lost when logging out

Interchange user interchange-users@icdevgroup.org
Tue Nov 5 13:25:04 2002


> > > If I log in and log out again, and then go to the checkout page, my
> > > shipping routine is not returning anything. I have found that this is
> > > because the [value country] variable that is normally passed to it is
> > > lost upon logging out. It will stay this way until I hit 'recalculate',
> > > change the country, or log back in, even if I go to another page and
> > > then come back to the checkout page.
> >
> >
> >You could modify your catalog.cfg to include this directive:
> >
> >     ValuesDefault  country  GB
> >
> >Where 'GB' is the default to be set (change to whatever you need).
> >The [value country] will be initialised with the default whenever a
> >new session is allocated.
>
>
> But that doesn't solve the little problem he is describing, which is
> logging out (which clears the country value) within the same session, then
> returning to the checkout page. In that case, just add something like this
> to the top of ord/checkout.html:
>
> [value name=country set="[either][value country][or]US[/either]" hide=1]
>
> ... you could also use the default country variable from the variable table
> as the settor instead of 'US'
>
> - Ed L.

Ed,

Excellent; that works fine!

I did try [value country set=UK], but I obviously got the syntax wrong, 
leaving out 'name=', and it would have been useless without the [either] & 
[or] tags.

Thanks for your help.