Mail - Problem
| From: | eL RaNu | Date: | Fri, 21 Feb 2003 23:23:21 +0000 |
| Subject: | Mail - Problem | ||
| Groups: | php.pear.dev | ||
| Request: | Send a blank email to pear-dev+get-13611@lists.php.net to get a copy of this message | ||
Hi,
I want to send mails with the smtp of my isp. So i use this code for test it. But it dosen´t work, it dosen´t send the mail. Does any one know why? My server is under SuSE 8.0, with a firewall. The firewall is in iptables. Do I have to open any port to make it work?Thanks, <?php include('Mail.php'); $recipients = 'elranu@fibertel.com.ar';
$headers['From'] = 'nuevo-evento@q-orum.com.ar'; $headers['To'] = 'elranu@fibertel.com.ar';$headers['Subject'] = 'Test message'; $body = 'Test message'; $param["host"]='smtp.fibertel.com.ar'; $param["port"]='25'; $param["auth"]='true'; $param["username"]='elranu'; $param["password"]='pass'; // Create the mail object using the Mail::factory method $mail_object =& Mail::factory('smtp', $param); $mail_object->send($recipients, $headers, $body); print("Mail Sent"); ?> Thanks,
eL RaNu