Help for this page

Select Code to Download


  1. or download this
    $ENV{TZ}="US/Eastern";
    # use locatime(time) to get the time
    $ENV{TZ}="Other/Zone";
    # use localtime(time) to get the time
    # subtract the difference
    
  2. or download this
    my $rfc_offset = `TZ=US/Eastern; date +%s`;
    my $rfc_offset2= `TZ=Other/Zone; date +%s`;
    # code to work out difference in seconds.