[Xapian-tickets] [Xapian] #314: query.cc: $date returns time in GMT only
Xapian
nobody at xapian.org
Sun Mar 1 12:05:50 GMT 2009
#314: query.cc: $date returns time in GMT only
--------------------+-------------------------------------------------------
Reporter: sage | Owner: olly
Type: defect | Status: assigned
Priority: normal | Milestone: 1.1.1
Component: Omega | Version: 1.0.9
Severity: normal | Resolution:
Keywords: | Blockedby:
Platform: All | Blocking:
--------------------+-------------------------------------------------------
Changes (by olly):
* milestone: 1.1.0 => 1.1.1
Comment:
Further research reveals that you can't actually get the user's timezone
from javascript. You can get the current offset from UTC, but that
doesn't tell you how much offset to apply for arbitrary dates - it could
easily be 2 hours wrong (e.g. UK DST to NZ non-DST vs UK non-DST to NZ
DST).
The best option seems to be to write out javascript code to output the
time_t values as a formatted date, like the patch I'll attach shortly.
This doesn't seem ideal though - it's kind of
klunky, and changing the date formatting is very fiddly and error prone.
I don't think we need to hold up 1.1.0 for this, so moving the milestone
setting. If we come up with a clean fix (or decide the attached patch is
actually OK) it can go in for 1.1.0 of course.
--
Ticket URL: <http://trac.xapian.org/ticket/314#comment:2>
Xapian <http://xapian.org/>
Xapian
More information about the Xapian-tickets
mailing list