On Thursday 22 January 2004 21:57, Stefan Schmidt wrote: > Hi@ll ! > > If i call a script within the following code: > > #!/usr/local/bin/perl > use DateTime; > my $dt = DateTime->new( year => 2000, month => 5, day => 10, > hour => 15, minute => 15, > time_zone => 'GMT', ); > print $dt->hour."\n"; > $dt->set_time_zone( 'Europe/Berlin' ); > print $dt->hour."\n"; It works perfectly, you just have to think about what you said the module. Month is 5 (May) and IIRC this is (summer) standard time, therefore the script says 15 17 But if you change the Month to 12 (December) it is daylight-saving (winter) time, so the script gives. 15 16 First look for the bug in your code, then for the bug in code written by someone else :-) Have fun, Marcus -- --------------------------------------------------------- |Marcus Thiesen ICQ# 108989768| --------------------------------------------------------- | www.thiesenweb.de | --------------------------------------------------------- 28A7 37CC AE2C BB6C D56D 8A3D E614 E56B 7546 75F2
Attachment:
pgpgEYVTFYEFH.pgp
Description: signature