The timezone problem
    Gervase Markham 
    gerv at mozilla.org
       
    Tue Nov 17 14:45:10 UTC 2009
    
    
  
On 13/10/09 17:14, Gervase Markham wrote:
> So I'm looking at trying to solve (as best I can) the timezone problem
> for my API.
OK, I think I've cracked this. Every timezone on the API is now output 
in the following form:
YYYY-MM-DDTHH:MM:SSZ
(literal T and Z), which is ISO 8601 extended format. And assuming you 
tell the API what the timezone of the target Bugzilla is, all the 
timestamps are correct.
(Yes, I could have determined this programmatically at every startup, 
but it seemed easier to just have it as a config.)
I _think_ this will work even if the user changes their TZ preferences, 
because the stamps output still have TZ info attached, which means I can 
convert back to UTC.
Gerv
_______________________________________________
dev-apps-bugzilla mailing list
dev-apps-bugzilla at lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-apps-bugzilla
    
    
More information about the developers
mailing list