-<!-- mason kludge -->
-%
-%
-%my $conf = new FS::Conf;
-%die "Customer deletions not enabled" unless $conf->exists('deletecustomers');
-%
-%my($custnum, $new_custnum);
-%if ( $cgi->param('error') ) {
-% $custnum = $cgi->param('custnum');
-% $new_custnum = $cgi->param('new_custnum');
-%} else {
-% my($query) = $cgi->keywords;
-% $query =~ /^(\d+)$/ or die "Illegal query: $query";
-% $custnum = $1;
-% $new_custnum = '';
-%}
-%my $cust_main = qsearchs( 'cust_main', { 'custnum' => $custnum } )
-% or die "Customer not found: $custnum";
-%
-%print header('Delete customer');
-%
-%print qq!<FONT SIZE="+1" COLOR="#ff0000">Error: !, $cgi->param('error'),
-% "</FONT>"
-% if $cgi->param('error');
-%
-%print
-% qq!<form action="!, popurl(1), qq!process/delete-customer.cgi" method=post>!,
-% qq!<input type="hidden" name="custnum" value="$custnum">!;
-%
+<% include('/elements/header.html', 'Delete customer') %>
+
+<% include('/elements/error.html') %>
+
+<FORM ACTION="<% popurl(1) %>process/delete-customer.cgi" METHOD=POST>
+<INPUT TYPE="hidden" NAME="custnum" VALUE="<% $custnum |h %>">
+