$sql = <<<SQL
insert into tbregister values('$username','$password','$password2','$firstname','$lastname','$company','$gender','$day','$month','$year','$email','$address','$country',$postal_code,$tel,$fax,$mobile,'$favourite_color');
SQL;
include "connectdb.php";
include "function.php";
$result=mysql_query($sql);
$msg = "";
$resetForm = "";
if($link==0){
$msg = "<p class='red2' align='center'>";
$msg .= "Sorry, you are not able to be registered.";
echo "<meta http-equiv='refresh' content='5; url=re_cus.php' />";
}
else{
echo "<p class='red2' align='center'>Thank you. You are already registered.</p>";
echo "<meta http-equiv='refresh' content='5; url=service.php' />";
$resetForm = "document.getElementById('myForm').reset();";