lyric0n
Technical User
- Dec 28, 2005
- 74
Hello,
I have an application that dumps a date into a MySQL table with object type of text. It is dumping a date into the table, but it doesn't store it as a date, I believe it is running it through a serialize function, then putting it in there. So a date of 6/10/2007 becomes a:3:{s:5:"month";s:1:"6";s:3:"day";s:1:"10";s:4:"year";s:4:"2007";}.
How would I convert the the string back into a date? I've tried using the unserialize function, but am having all sorts of difficulties. Any suggestions?
Thanks,
Chris
I have an application that dumps a date into a MySQL table with object type of text. It is dumping a date into the table, but it doesn't store it as a date, I believe it is running it through a serialize function, then putting it in there. So a date of 6/10/2007 becomes a:3:{s:5:"month";s:1:"6";s:3:"day";s:1:"10";s:4:"year";s:4:"2007";}.
How would I convert the the string back into a date? I've tried using the unserialize function, but am having all sorts of difficulties. Any suggestions?
Thanks,
Chris