Forum Moderators: coopster

Message Too Old, No Replies

PHP 5.2.11 Released!

over 75 bug fixes

         

coopster

2:26 pm on Sep 18, 2009 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Lots of fixes across the board including ssl, image processing, cURL, ... the list goes on!

Release Announcement [php.net]
ChangeLog [php.net]

coopster

3:29 pm on Sep 18, 2009 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



One noticeable improvement is that the Win32 package's included sendmail binary has been updated to include a new function, FormatEmailAddress.

/********************************************************************* 
// Name: int FormatEmailAddress
// Input:
// Output:
// Description: Formats the email address to remove any content ouside
// of the angle brackets < > as per RFC 2821.
//
// Returns the invalidly formatted mail address if the < > are
// unbalanced (the SMTP server should reject it if it's out of spec.)
//
// Author/Date: garretts 08/18/2009
// History:
//********************************************************************/
static int FormatEmailAddress(char* Buffer, char* EmailAddress, char* FormatString) {
char *tmpAddress1, *tmpAddress2;
int result;
if( (tmpAddress1 = strchr(EmailAddress, '<')) && (tmpAddress2 = strchr(tmpAddress1, '>')) ) {
*tmpAddress2 = 0; // terminate the string temporarily.
result = snprintf(Buffer, MAIL_BUFFER_SIZE, FormatString , tmpAddress1+1);
*tmpAddress2 = '>'; // put it back the way it was.
return result;
}
return snprintf(Buffer, MAIL_BUFFER_SIZE , FormatString , EmailAddress );
} /* end FormatEmailAddress() */

Anybody that has ever attempted to send bracketed emails from a local Win machine is going to know right away what I'm talking about here. I'm guessing garretts is Garrett Serack, the open source software developer at Microsoft who's involved with the company's Open Source Technology Center. If so, Mr. Serack, I want to be the first to thank you. First one's on me if we ever meet!