#!/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);

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

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

# display tabs
require $tabdisplay;

$ipaddress = param('ipaddress');

print_header ("Creation of SMTP forwarding for $domainname");

if ( is_ip_address_syntax_correct($ipaddress) eq "no" )
{
	print "Sorry, but the format of the IP address you supplied ($ipaddress) does not seem to be correct.";
	print_support_contact_information();	
} else {
	print "
	<form method=post action=/$script_bin/$final_confirm_create_smtp_forwarding class=text>
	<input type=hidden name=ipaddress value=$ipaddress>
	Installing SMTP forwarding to $ipaddress will have the following effects on your current email setup:<BR>
	<ul class=text>
	<li>all your email users/accounts will be ignored;</li>
	<li>emails that arrive from this moment on will not be available through webmail or pop3 from our servers</li>
	<li>you will not receive emails until your mail server at the IP address $ipaddress is correctly configured</li>
	<form method=post action=/$script_bin/$final_confirm_create_smtp_forwarding class=text>
	<input type=hidden name=ipaddress value=$ipaddress>
	</ul>
	<span class=text>
	If you are satisfied with these consequences of installing SMTP forwarding on your account, please click on the 
	button to proceed.</span>
	";

	print_end_of_form();
}

require $footer;
