#!/usr/bin/perl

print "Content-Type: Text/HTML\n\n";

use CGI ':standard';
use Vpanel 1.00;
require $header;
require $accountinfo;
$domainname = find_domain ($mainuser);
$chosen_user = param('user');

# Define the tab which appears to the front
$tab_section = $tabnum_website;

# Output the content associated with this tab
print "<body class=section-$tab_section>";

# display tabs
require $tabdisplay;

@ftp_user_list = find_valid_ftp_users($domainname);
$num_ftp_users = @ftp_user_list;

print_header ("Deletion of an FTP user for $domainname");

print<<HEADER;

Please select the user you wish to delete from the list below and click on the submit button.<BR>

<form method=post action="/$script_bin/$confirm_delete_ftp_user" class=text>
<select name=user>

HEADER

for ( $i = 0 ; $i < $num_ftp_users ; $i++)
{
	print "<option value=$ftp_user_list[$i]";
	if ( $chosen_user eq $ftp_user_list[$i] )
	{
		print " selected ";
	}
	print ">$ftp_user_list[$i]";
}

print "</select>";

print_end_of_form();

require $footer;
