Re: ParseDate.parsedate() and Time.now()

I’m not sure it’ll change. You’re on Windows, and Windows is
stupid this way, preferring to spell out “Central Daylight
Time” instead of “CDT”; I have yet to figure out how to get
the output from a Windows format string to be abbreviated or
better yet to return a +/- offset.

Modify your registry:

http://www.artima.com/forums/flat.jsp?forum=123&thread=158847

Or did you mean something else?

Regards,

Dan

This communication is the property of Qwest and may contain confidential
or
privileged information. Unauthorized use of this communication is
strictly
prohibited and may be unlawful. If you have received this communication
in error, please immediately notify the sender by reply e-mail and
destroy
all copies of the communication and any attachments.

On 8/15/06, Berger, Daniel [email protected] wrote:

Modify your registry:
Ruby Buzz Forum - Dealing with TZ parsing (on Windows)

Useful. You realize it points to your own blog, don’t you? :wink:

Or did you mean something else?

We should probably fix ParseDate. But that’s hard and ugly.

-austin

On Tue, 15 Aug 2006, Berger, Daniel wrote:

Or did you mean something else?

Regards,

Dan

why aren’t you guys just using a decent date format?

require ‘time’

now = Time.now

iso8601 = now.iso8601(2)

puts iso8601

now2 = Time.parse(iso8601)

iso86012 = now2.iso8601(2)

my rules for dealing with dates are

  • do everything in gmt

  • if, and only if, that cannot be done do all calculations/formatting
    using
    iso8601. it sorts as strings and is parseable by just about any
    decent
    application including databases and does not require tzinfo.

regards.

-a