Page 2 of 2

Posted: Sun Apr 22, 2007 10:59 am
by Chris Corbyn
Changes are available in 3.1.4. I have never been able to recreate the hang myself so I'm just crossing my fingers :)

Posted: Mon Apr 23, 2007 3:24 am
by stonedyak
3.1.4 works with no problems for me. Thanks for the quick fix!

Posted: Thu May 10, 2007 10:18 am
by chazter6
Update on my original post.

I downloaded the latest version for PHP4 Swift-3.2.1 and tested it at my ISP and it works with success.

I used:

Immediately goes to my destination

Code: Select all

require_once ("swift/lib/Swift.php");
require_once ("swift/lib/Swift/Connection/NativeMail.php");

$swift =& new Swift(new Swift_Connection_NativeMail());

//Create the message
$message =& new Swift_Message("My subject Native", "My body");
 
//Now check if Swift actually sends it
if ($swift->send($message, "to@domain.tld", "webmaster@domain.tld")) echo "Sent";
else echo "Failed";

Immediately goes to my destination

Code: Select all

require_once ("swift/lib/Swift.php");
require_once ("swift/lib/Swift/Connection/Sendmail.php");

//Start Swift
$swift =& new Swift(new Swift_Connection_Sendmail(SWIFT_SENDMAIL_AUTO_DETECT));

//Create the message
$message =& new Swift_Message("My subject AUTO_DETECT", "My body");
 
//Now check if Swift actually sends it
if ($swift->send($message, "to@domain.tld", "webmaster@domain.tld")) echo "Sent";
else echo "Failed";
Reaches my desitnation about 2 minutes later, It will be either redirected as SPAM (Redirected to my Yahoo Bulk Folder) or also does reaches my INBOX of my yahoo account. It just depends I guess what the provider wants to do.

Code: Select all

require_once ("swift/lib/Swift.php");
require_once ("swift/lib/Swift/Connection/Sendmail.php");

//Start Swift
$swift =& new Swift(new Swift_Connection_Sendmail());

//Create the message
$message =& new Swift_Message("My subject Sendmail", "My body");
 
//Now check if Swift actually sends it
if ($swift->send($message, "to@domain.tld", "webmaster@domain.tld")) echo "Sent";
else echo "Failed";
Would you know why my 3rd option is a bit inconsitent? If not no worries...at least I have a couple of options.
Thanks for your new updates!

Posted: Thu May 10, 2007 10:45 am
by Chris Corbyn
I'm afraid I have no idea. Leaving the constructor empty defaults to /usr/sbin/sendmail. I'm guessing AUTO_DETECT is picking up a different binary or something (which might be smarthosted to another server in a RBL, which would also explain the 2 minute delay).

It's quite common for sendmail binaries to be smarthosted. This basically means they take the mail, spool it, the rather than sending it they forward it to another server to do the sending. That's my stab in the dark ;)