##this section looks up the DNS host name of a given IP address use Socket; $gothostbyaddr=gethostbyaddr($address, 2); ##this section forms and email and sends use OLE; $Mailer = CreateObject OLE 'SMTPsvg.Mailer'; $Mailer->{'FromName'} = 'whatevername'; $Mailer->{'FromAddress'} = 'whatever@mysite.com'; $Mailer->{'RemoteHost'} = 'websmtp.mysite.com'; $Mailer->AddRecipient('Recipient', 'receipient@yoursite.com'); $Mailer->{'Subject'} = "Title page"; $Mailer->{'BodyText'} = "$address is $gothostbyaddr"; if ($Mailer->SendMail()) { print "Mail successfully sent", "\n"; } else { print $Mailer->{'Response'},"Mail failure. Check mail host server name and tcp/ip connection...", "\n"; }