MiniVend Akopia Services

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

Need help: checkout.html (II)



******    message to minivend-users from Oliver Schade <schade@outsource.de>     ******


Hi again,

On Fri, 5 Mar 1999, minivend-users wrote:
> Date: Fri, 5 Mar 1999 14:52:13 +0100
> From: Frank Miedreich <miedreich@acm.org>
> Subject: Re: Need help: Adjusting checkout.html

[Customising checkout.html]

> 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]

This even does not work :-(( Well, the facts:

  [vat][subtotal noformat=1][/vat]

works and gives a number without any currency symbols.

  UserTag Routine sub { my ($a) = @_; return ($a); }

works and returns just this unformatted number.

  UserTag Routine sub { my ($a) = @_; return ($a/100); }

returns in every case 0.

  UserTag Routine sub { my ($a) = @_; return ($a-$a/1.16); }

returns in every case 0.

  UserTag Routine sub { my ($a) = @_; local($b) = $a+100; return $b; }

returns 100 (*argh*).

Disabling UserTag Interpolate 1 has no effect. Is seems, that any arithmetic
sets $a to zero... :-((( Any more ideas, please?

Thanks for all other hints, most of them are working (expect this tricky one).

Ciao, Oliver
-- 
"Eher werden die Windows-NT-Sourcen unter die GPL gestellt, als dass 
 Microsoft auch nur die Existenz von was anderem als Windoof anerkennt,
 geschweige denn unterstuetzt" [Christoph Lorenz in de.comp.os.linux.misc]
 [<A HREF="http://mitarbeiter.mbi-berlin.de/schade/">My Homepage</A>]


-
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: