07Jul

The time is wrong on my emails sent by php sendmail script?

5 comments so far


I am sending emails using the php sendmail script. The problem is, the server is on a different timezone than I am and the emails appear to have been send 5 hours before. Is there a way to change the time sent on email in php? I am using php on a Windows platform - v5.0
Just a reminder, I am using an older version of PHP that apparently does NOT allow you to set the timezone.

Share and Enjoy: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Digg
  • del.icio.us
  • StumbleUpon
  • Reddit
  • Webnews
  • MisterWong
  • Y!GG
Categories: Programming & Design

Wednesday, July 7th, 2010 at 4:33 pm and is filed under Programming & Design. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

5 Responses to “The time is wrong on my emails sent by php sendmail script?”

  1. Posted by I Love Ubuntu 9th July, 2010 at 1:33 pm

    if you look at source #1, it will have the syntax for the mail(); function. Date looks like it should be in the additional headers section. Try looking into that.

  2. Posted by Gokul G 11th July, 2010 at 7:38 pm

    I think its belong to the time of your server

  3. Posted by dhvrm 12th July, 2010 at 6:35 pm

    Add the datetime you want to use as an additional header.

  4. Posted by SSE 15th July, 2010 at 7:46 pm

    Version 5 of PHP is not an “older” version, it’s still actually pretty new, as v6 is not in widespread use yet.

    Other than that, I can only suggest that you look into mail headers. There are options for time/date there.

  5. Posted by Security Guy 17th July, 2010 at 8:04 pm

    I found a site good for programmers to ask questions. There are some experienced programmers there, so you can get help there. It’s free by the way.

Leave a reply