I ran into an issue with my dedicated MediaTemple (not an affiliate link) server today.
This works on my local WAMP development server:
$timestamp = date(DATE_RFC822);
It doesn’t when I post the same code to my dedicated virtual server at MediaTemple. Looks like their date constants are all disabled, and I don’t have time to wait around for support. So, here’s the workaround:
// Manual translation into RFC822 format, e.g. “Mon, 15 Aug 2005 15:52:01 UTC”
$timestamp   = gmdate(”D, d F Y H:i:s”);
$timestamp .= ” UTC”;
Enjoy.
Discussion
No comments for “Host with MediaTemple? Here’s a workaround for PHP Date Constants”
Post a comment