sub sendpasstoemail { my $smtp; my $pingStatus; my $localcount; my $subject = "User \'$1\' Booking Request for ATCA Chassis"; my $string = <new('ORCAS01.hotmail.com'); $smtp->mail($3); $smtp->to($3); $smtp->data(); $smtp->datasend("From: Booking and Managment system\n"); $smtp->datasend("To:$3\n"); $smtp->datasend("Subject: $subject\n"); $smtp->datasend("\n"); $smtp->datasend("$string\n"); $smtp->dataend(); $smtp->quit; print $query->h2({-align=>'center'},"Your request message is sent to Chassis user"); }