+</SCRIPT>
+
+<BR>
+<FONT CLASS="fsinnerbox-title"><% mt('Service address') |h %></FONT>
+
+<INPUT TYPE="checkbox" NAME="same" VALUE="Y" onClick="samechanged(this)" <%$same_checked%>><% mt('same as billing address') |h %>
+<& cust_main/contact.html,
+ 'cust_main' => $cust_main,
+ 'pre' => 'ship_',
+ 'onchange' => '',
+ 'disabled' => $ship_disabled,
+ 'style' => \@ship_style
+&>
+
+<& cust_main/contacts_new.html,
+ 'cust_main' => $cust_main,
+&>
+
+%# billing info
+<& cust_main/billing.html, $cust_main,
+ 'payinfo' => $payinfo,
+ 'invoicing_list' => \@invoicing_list,
+&>
+<BR>
+
+% my $ro_comments = $conf->exists('cust_main-use_comments')?'':'readonly';
+% if (!$ro_comments || $cust_main->comments) {
+
+ <BR>
+ <FONT CLASS="fsinnerbox-title"><% mt('Comments') |h %></FONT>
+ <TABLE CLASS="fsinnerbox">
+ <TR>
+ <TD>
+ <TEXTAREA NAME = "comments"
+ COLS = 80
+ ROWS = 5
+ WRAP = "HARD"
+ <% $ro_comments %>
+ ><% $cust_main->comments %></TEXTAREA>
+ </TD>
+ </TR>
+ </TABLE>
+
+% }
+
+% unless ( $custnum ) {
+
+ <& cust_main/first_pkg.html, $cust_main,
+ 'pkgpart_svcpart' => $pkgpart_svcpart,
+ 'disable_empty' =>
+ scalar( $cgi->param('lock_pkgpart') =~ /^(\d+)$/ ),
+ 'username' => $username,
+ 'password' => $password,
+ 'popnum' => $popnum,
+ 'saved_domsvc' => $saved_domsvc,
+ %svc_phone,
+ %svc_dsl,
+ &>
+
+% }
+
+<INPUT TYPE="hidden" NAME="locationnum" VALUE="<% $locationnum %>">
+
+<INPUT TYPE="hidden" NAME="usernum" VALUE="<% $cust_main->usernum %>">
+
+%# cust_main/bottomfixup.js
+% foreach my $hidden (
+% 'payauto', 'billday',
+% 'payinfo', 'payinfo1', 'payinfo2', 'payinfo3', 'paytype',
+% 'payname', 'paystate', 'exp_month', 'exp_year', 'paycvv',
+% 'paystart_month', 'paystart_year', 'payissue',
+% 'payip',
+% 'paid',
+% ) {
+ <INPUT TYPE="hidden" NAME="<% $hidden %>" VALUE="">
+% }
+
+<& cust_main/bottomfixup.html, 'custnum' => $custnum &>
+
+<BR>
+<INPUT TYPE = "button"
+ NAME = "submitButton"
+ ID = "submitButton"
+ VALUE = "<% $custnum ? emt("Apply changes") : emt("Add Customer") %>"
+ onClick = "this.disabled=true; bottomfixup(this.form);"
+>
+<BR><BR>
+</FORM>
+
+<& /elements/footer.html &>
+
+<%init>
+
+my $curuser = $FS::CurrentUser::CurrentUser;
+
+#probably redundant given the checks below...
+die "access denied"
+ unless $curuser->access_right('New customer')
+ || $curuser->access_right('Edit customer');