I am having a hard time importing single years from CSV file. I have verified my CSV file is correct, i.e. the year I'm trying to import is 2003.
I'm trying to import this to a node, and the field in my node of of type "Date" and the "customize input format" is set to Y.
However, whenever I import, all I get as a result is 2012.
| Comment | File | Size | Author |
|---|---|---|---|
| #1 | feeds-import-single-year-1537776-1.patch | 1011 bytes | David_Rothstein |
Comments
Comment #1
David_Rothstein commentedI ran into this too, but discovered it only happens if the year is 2000 or later (!).
After a lot of searching, I came across http://aaronsaray.com/blog/2007/07/11/helpful-strtotime-reminders/#comme... which explains it. Crazy stuff!
The attached patch contains a simple fix.
Comment #2
twistor commentedThat is a fun one.
http://drupalcode.org/project/feeds.git/commit/2c05963
I added a test and removed the is_int() check for the timestamp.
Comment #3
twistor commented