1 <%= include('header', 'Edit service address') %>
4 $OUT .= qq!<FONT SIZE="+1" COLOR="#ff0000">Error: $error</FONT><BR><BR>!;
7 <FORM NAME="OneTrueForm" ACTION="<%= $selfurl %>" METHOD=POST onSubmit="document.bottomform.submit.disabled=true;">
8 <INPUT TYPE="hidden" NAME="action" VALUE="process_change_ship">
9 <TABLE BGCOLOR="#cccccc" BORDER=0 CELLSPACING=0>
13 qw( last first company address1 address2 city county state zip country
16 $OUT .= qq!<INPUT TYPE="hidden" NAME="$_" VALUE="${$_}">!;
21 function bill_changed(what) {
22 if ( what.form.same.checked ) {
24 for (qw( last first company address1 address2 city zip daytime night fax )) {
25 $OUT .= "what.form.ship_$_.value = what.form.$_.value;";
29 what.form.ship_country.selectedIndex = what.form.country.selectedIndex;
31 function fix_ship_county() {
32 what.form.ship_county.selectedIndex = what.form.county.selectedIndex;
35 function fix_ship_state() {
36 what.form.ship_state.selectedIndex = what.form.state.selectedIndex;
37 ship_state_changed(what.form.ship_state, fix_ship_county );
40 ship_country_changed(what.form.ship_country, fix_ship_state );
44 function samechanged(what) {
49 for (qw( last first company address1 address2 city county state zip country daytime night fax )) {
50 $OUT .= "what.form.ship_$_.disabled = true;";
51 $OUT .= "what.form.ship_$_.style.backgroundColor = '#dddddd';";
53 if ( $require_address2 ) {
54 $OUT .= "document.getElementById('ship_address2_required').style.visibility = 'hidden';";
55 $OUT .= "document.getElementById('ship_address2_label').style.visibility = 'hidden';";
62 for (qw( last first company address1 address2 city county state zip country daytime night fax )) {
63 $OUT .= "what.form.ship_$_.disabled = false;";
64 $OUT .= "what.form.ship_$_.style.backgroundColor = '#ffffff';";
66 if ( $require_address2 ) {
67 $OUT .= "document.getElementById('ship_address2_required').style.visibility = '';";
68 $OUT .= "document.getElementById('ship_address2_label').style.visibility = '';";
74 (<INPUT TYPE="checkbox" NAME="same" VALUE="Y" onClick="samechanged(this)"
75 <%= (!$ship_last || $cgi->param('same') eq 'Y') ? 'CHECKED' : '' %>
76 >same as billing address)
77 <%= $r=qq!<font color="#ff0000">*</font> !;
78 if (!$ship_last || $cgi->param('same') eq 'Y') {
79 $disabled = 'DISABLED STYLE="background-color: #dddddd"';
80 foreach ( qw( last first company address1 address2 city county state
81 zip country daytime night fax )
92 <INPUT TYPE="submit" NAME="submit" VALUE="<%= $custnum ? "Apply Changes" : "Add Customer" %>">
96 <%= include('footer') %>