I have been using Bugzilla as a bug tracker for quite some time. However,recently i was involved in setting up Mantis , which is another free and open source bug tracking system .Unlike Bugzilla which is Perl based, Mantis is written in PHP.

I had a strange problem with email notifications being sent out by Mantis. When the emails arrived in my inbox,the inbox view showed ‘Unknown Date’ in the date field for the mails. Mantis uses PHPMailer as the mail library. This bug has been discussed on the PHPMailer mailing list. Quoting the solution below.

In class.phpmailer.php ’s function RFCDate(), there is a bug in the timezone code which returns +0580 for Indian Standard Time instead of +0530.

The line

$tz = ($tz/3600)*100 + ($tz%3600)/60;


should be replaced with

$tz= (($tz - ($tz%3600) )/3600)*100 + ($tz%3600)/60;

After patching my Mantis installation with the fix, the issue was resolved.Hope this helps someone else faced with the same problem…have fun :)