[comment] ui_template: Yes ui_template_name: noleft [/comment] [tmp page_title]__COMPANY__ -- [L]Billing Address[/L][/tmp] @_NOLEFT_TOP_@ [if !cgi mv_same_billing] [value name=mv_same_billing set=""] [/if] [if value mv_same_billing] [if session logged_in] [tmp tmp_save_billing][userdb function=set_billing nickname=default][/tmp] [calc]Debug('Saved billing: ' . $Scratch->{tmp_save_billing})[/calc] [/if] [loop list="fname lname company address1 address2 city state zip country phone"][value name="b_[loop-code]" set=""][/loop] [/if] [bounce href="[area href=ord/shipmode secure=1]" if="[value mv_same_billing]"] [if !value b_address1] [if session logged_in] [tmp tmp_get_billing][userdb function=get_billing nickname=default][/tmp] [/if] [/if] [if session logged_in] [if cgi get_billing] [userdb function=get_billing nickname="[cgi get_billing]" hide=1] [tmp get_message](set from [cgi get_billing])[/tmp] [/if] [userdb get_billing_names] [else] [value name=accounts set=""] [/else] [/if] [include include/checkout/initialization]
[form-session-id] [tmp clear_errors][error all=1 comment="Clear errors"][/tmp]
[if !variable NO_TAX_POPUP] [comment] This is JavaScript that pops up a tax message when in simple tax mode [/comment] [include include/checkout/tax_popup] [/if] [if type=explicit compare="[error all=1 show_var=1 keep=1]"] [tmp error_display]

[L]There were errors in your last submission[/L]:

[error all=1 keep=1 show_error=1 show_label=1 joiner="
"]

[msg arg.0="" arg.1=""]Please correct the areas listed above which are highlighted in %sthis color%s in the form.[/msg]

[/tmp] [/if] [set Check_billing] [if !cgi mv_same_billing] &fatal=no &update=yes &fail=@@MV_PAGE@@ [calc] if ($CGI->{b_state_cs_in} && !$CGI->{b_state}){ $CGI->{b_state} = $CGI->{b_state_cs_in}; } return; [/calc] [if session logged_in] [tmp tmp_save_billing][userdb function=set_billing nickname=default][/tmp] [/if] b_fname=required b_lname=required b_address1=required b_city=required b_country=required b_state=multistate &fatal=yes b_zip=multizip [/if] [/set] [comment] Form intro -- the input elements are largely in the individual tables in include/checkout/* [/comment]
Billing Address [scratch get_message]
[if scratch error_display] [/if]
 
Same as shipping address
 
[error name=b_fname std_label="[L]First Name[/L]" required=1] [error name=b_lname std_label="[L]Last Name[/L] " required=1]
[error name=b_company std_label="[L]Company[/L]"]
[error name=b_address1 std_label="[L]Address[/L]" required=1]
 
[error name=b_city std_label="[L]City[/L]" required=1] [error name=b_state std_label="[L]State/Province[/L]" required=1] [display name=b_state type=state_select value="[value b_state]"]
[error name=b_zip std_label="[L]Zip/Postal Code[/L]" required=1]
[error name=b_country std_label="[L]Country[/L]" required=1] [display name=b_country type=country_select value="[value b_country]"]
  [if value accounts]
Use account from account book:
| [loop list="[value accounts]"] [page href=@@MV_PAGE@@ form="get_billing=[loop-code]" ][loop-code] - [data table=userdb col=accounts.[loop-code].b_city key="[data session username]" serial=1] | [/loop]
[/if] [if session logged_in] [page href=member/bill_addresses form="destination=@@MV_PAGE@@"]Manage billing addresses [/if]
 
 

[scratchd error_display]
 
@_NOLEFT_BOTTOM_@