[ic] passing variables to usertags

Jonathan Clark interchange-users@lists.akopia.com
Fri Jul 20 14:41:00 2001


> UserTag austpost_calc HasEndTag
>
> Usertag austpost_calc Order Height Length Width Weight Quantity
> Pickup_Postcode Destination_Postcode Country Service_Type
>
> UserTag austpost_calc Routine <<EOF
>
> sub {
> my ( $Height, $Length, $Width, $Weight, $Quantity, $Pickup_Postcode,
> $Destination_Postcode, $Country, $Service_Type ) = @_ ;
>
> ::logGlobal("calling with: " . join("|", $Height, $Length, $Width,
> $Weight, $Quantity, $Pickup_Postcode, $Destination_Postcode, $Country,
> $Service_Type));
>
> --------------------------------------------------------
>
> I call this from an interchange page with
>
> [austpost_calc] Height=100 Length=100 Width=100 Weight=500 Quantity=1
> Pickup_Postcode=6167 Destination_Postcode=2014 Country=US
> Service_Type=Express [/austpost_calc]
>

With the code for your usertag, i think you should be using:

[austpost_calc Height=100 Length=100 Width=100 Weight=500 Quantity=1
Pickup_Postcode=6167 Destination_Postcode=2014 country=US
Service_Type=Express] [/austpost_calc]

I think using the HasEndTag will just put the contained text into the last
variable - not really what you want to do with your parameters.

Jonathan
Webmaint.