php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #14828 Timezone on mail timestamp early by 12 hours
Submitted: 2002-01-03 12:07 UTC Modified: 2002-06-02 19:51 UTC
Votes:9
Avg. Score:4.4 ± 0.8
Reproduced:8 of 8 (100.0%)
Same Version:6 (75.0%)
Same OS:0 (0.0%)
From: whitej at gmx dot net Assigned:
Status: Not a bug Package: Mail related
PHP Version: 4.1.1 OS: Windows NT4 SP6a
Private report: No CVE-ID: None
 [2002-01-03 12:07 UTC] whitej at gmx dot net
I experienced a similar problem in php 4.06, but the time was only off by 6 hours.  Now the time is off by 12 hours.  Here's a sample of the mail headers...notice the "Date" line:

Return-Path: <dlab-rva-system@lists.wcom.com>
Received: from dgismtp03.wcomnet.com ([166.38.58.143]) by
          pmmsg00.wcomnet.com (Netscape Messaging Server 4.15) with ESMTP
          id GPDFZW00.ALE for <justin.white@wcom.com>; Thu, 3 Jan 2002
          16:47:56 +0000 
Return-path: jack.duruji@wcom.com
Received: from CONVERSION-DAEMON by dgismtp03.wcomnet.com (PMDF V5.2-33 #42262)
 id <0GPD00H01FZVN5@dgismtp03.wcomnet.com> for justin.white@wcom.com; Thu,
 3 Jan 2002 16:47:55 +0000 (GMT)
Received: from dgismtp03.wcomnet.com by dgismtp03.wcomnet.com
 (PMDF V5.2-33 #42262) with SMTP id <0GPD00H01FZ8HB@dgismtp03.wcomnet.com> for
 justin.white@wcom.com; Thu, 03 Jan 2002 16:47:55 +0000 (GMT)
Received: from smtp.wcomnet.com ([166.35.132.178])
 by dgismtp03.wcomnet.com (PMDF V5.2-33 #42262)
 with ESMTP id <0GPD00FAVFZ5EE@dgismtp03.wcomnet.com> for
 justin.white@wcom.com; Thu, 03 Jan 2002 16:47:29 +0000 (GMT)
Received: from dlab - 166.35.132.178 by smtp.wcomnet.com  with Microsoft
 SMTPSVC(5.5.1774.114.11); Thu, 03 Jan 2002 10:47:36 -0600
Date: Thu, 03 Jan 2002 10:47:36 +0600
From: jack.duruji@wcom.com
Subject: D Lab RVA# 1178-02 for Project 1178 - AN-30 (Data Regression)
X-Sender: <jack.duruji@wcom.com>
To: justin.white@wcom.com
Cc: justin.white@wcom.com
Reply-to: jack.duruji@wcom.com
Message-id: <001c53647160312ESERVER@smtp.wcomnet.com>
X-Mailer: D Lab RVA System
X-Priority: 1

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-01-08 09:56 UTC] whitej at gmx dot net
This is similar in configuration to Bug #12680.
 [2002-02-08 22:07 UTC] gsanta at appliedreasoning dot com
I too have stumbled unto this problem.  A workaround is to add the following "Date" header to the mail() function call.

"Date: ".date("D, j M Y H:i:s -0600")."\r\n"

In my case, I'm at CST so -0600 is what does it for me.  Change yours as necessary.

Here's how I use it in my code:

mail($emailToAddress,
$g_welcomeMessageSubjectLine,
$welcomeMessage,
"From: ".$g_sendWelcomeMsgFrom."\r\n".
"Date: ".date("D, j M Y H:i:s -0600")."\r\n");

The mail then arrives with the correct timestamp in the user's mailbox.
 [2002-05-25 06:31 UTC] derick@php.net
reclassify
 [2002-06-02 19:51 UTC] mfischer@php.net
Thank you for taking the time to report a problem with PHP.
Unfortunately your version of PHP is too old -- the problem
might already be fixed. Please download a new PHP
version from http://www.php.net/downloads.php

If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Oct 14 08:01:27 2024 UTC