I am able to parse strings containing date/time with time.strptime
>>> import time
>>> time.strptime('30/03/09 16:31:32', '%d/%m/%y %H:%M:%S')
(2009, 3, 30, 16, 31, 32, 0, 89, -1)
I have a date of the form specified by RFC 2822 -- say Fri, 15 May 2009 17:58:28 +0000, as a string. Is there a quick and/or standard way to get ...
Fri, 15 May 2009 17:58:28 +0000
I can't remember which application I was using, but I do recall it having really neat date parsing/interpretation.
For example, you could type in 'two days ago' or 'tomorrow' and it would ...
Assuming the text is typed at the same time in the same (Israeli) timezone, The following free text lines are equivalent:
Wed Sep 9 16:26:57 IDT 2009
September 9th, 16:26:57
What I'm looking for is something that can translate 'tomorrow at 6am' or 'next moday at noon' to the appropriate datetime objects.
I'm using python, and want to parsing a string like "01-Jan-1995" to datetime type of python.
who can tell me how to do it? thanks.
I'm about to start working on a simple calendar app for a website I'm working on (using Django, but that fact's probably not relevant).
I'd like users to be able to enter ...
Does anyone know of a library - ideally Python, that can have a stab at pulling dates out of text?
"Shall we go to the library today" -> 21 Jan 10
I have a variable containing a string from which I want to parse the date. I tryed this:
date_string = "July 2010"
parsed_date = datetime.datetime.strptime(date_string, "%B %Y")
# datetime.datetime(2010, 7, 1, 0, ...