MiniVend Akopia Services

[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date ][Minivend by thread ]

Re: Need help: Adjusting checkout.html



******    message to minivend-users from Frank Miedreich <miedreich@acm.org>     ******

>******    message to minivend-users from Oliver Schade
><schade@outsource.de>     ******
>
>
>Aloha,
>
>On Thu, 4 Mar 1999, Dan Busarow wrote:
>> I'm guessing that what you really want for VAT is subtotal -
>>(subtotal//1.16)
>
>Yes. My fault...
>
>> UserTag vat HasEndTag
>> UserTag vat Interpolate
>> UserTag vat Routine sub { ($a) = @_; return $a-$a/1.16; }
>
>According to the minivend.cfg I changed this to
>
>UserTag vat hasEndTag   1
>UserTag vat Interpolate 1
>UserTag vat Routine <<EOF
>sub {
>    my ($a) = @_;
>    return ($a-$a/1.16);
>}
>EOF
>
>and included the suggested [vat][subtotal][/vat] in
>.../pages/ord/checkout.html
>
>But this results *always* in a number of 0 :-(( Any other ideas (yes, I
>restarted the server)?
>
>Many thanks for your help,
>
>Oliver

try this:

UserTag vat hasEndTag   1
UserTag vat Interpolate 1
UserTag vat Routine <<EOF
sub {
    my ($a) = @_;
    my $out ='';
    my $vat = $a-$a/1.16;
    $out .= '[currency]';
    $out .= "$a";
    $out .= '[/currency]';
    return $out;
}
EOF

and call with:
[vat][subtotal noformat=1][/vat]

I dont quite remember which version introduced the noformat parameter to
the various price displays. Try [subtotal noformat=1] someplace on a page
and see what you get. Usually I try out my solutions but I currently have
no telnet access to my shop server, and this should work unless I have a
mental block about interpolation order.

Frank

--
Frank Miedreich
Max-Planck-Institut fuer psychologische Forschung


-
To unsubscribe from the list, DO NOT REPLY to this message.  Instead, send
email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
Archive of past messages: http://www.minivend.com/minivend/minivend-list


Search for: Match: Format: Sort by: