[ic] order.profile logic commands

Brendan Crosser-McGay interchange-users@interchange.redhat.com
Mon Apr 29 22:03:01 2002


I was trying to perform some checks on some numbers for checking a date of
birth to see if it is past a certain age.  I tried this and it didn't work,
this code is from the orders.profile, all I get is

(elsif): No format check routine for 'value'

when I go through an order.  I guess that means the order profile is not
working, but I can't think of what could be wrong, from what I've seen from
the other order profiles, ITL can be used there without any problems, Any
help would be appreciated!

profiles.order    code follows:

__NAME__                            credit_card
fname=required
lname=required
address1=required
city=required
country=required
&set = timeyear [calc][time]%Y[/time]-18[/calc]
&set = timemonth [time]%m[/time]
&set = timeday [time]%d[/time]
[if value dob_year < timeyear]
	[then]
		&set = DOB_check 1
	[/then]
	[elsif value dob_year == timeyear]
		[if value dob_month == timemonth]
			[then]
			[if value dob_day == timeday]
					&set = DOB_check 1
				[elsif scratch dob_day < timeday]
					&set = DOB_check 1
				[/elsif]
			[/if]
			[/then]
		[elsif value dob_month < timemonth]
			&set = DOB_check 1
		[/elsif]
		[/if]
	[/elsif]
[/if]
DOB_check=required You cannot continue since you are under 18.
phone_check=required
[if !value phone_check == ""]
  [then]
    [if !value phone_day == ""]
    phone_day=phone
    [/if]

    [if !value phone_night == ""]
    phone_night=phone
    [/if]

    [if !value phone_mobile == ""]
    phone_mobile=phone
    [/if]
   [/then]
  [/if]
[if value country =~ /^(US|CA)$/i]
	state=state_province
	zip=postcode
[/if]

&fatal = yes
email=required
email=email

&set = mv_payment Incomplete

[if variable MV_PAYMENT_MODE]
&credit_card=standard keep __CREDIT_CARDS_ACCEPTED__
&charge=[var MV_PAYMENT_MODE][cgi mv_payment_test]
&set=mv_payment Real-time Credit Card (%c -- [var MV_PAYMENT_MODE])
[else]
&credit_card=standard __CREDIT_CARDS_ACCEPTED__
&set=mv_payment Credit Card (%c)
[/else]
[/if]

&calc = $Values->{mv_payment} =~ s/\%c/$Values->{mv_credit_card_type}/g; 1;
&final = yes
&setcheck=mv_email [value email]

-----------------------------------------
Brendan Crosser-McGay
brendan@paymentonline.com
-----------------------------------------