erum
02-07-2007, 09:27 PM
Hi,
What I need to do is take a date from an RSS feed (this part is done), which is in this format:
Sat, 01 Jul 2006 10:46:09 +0000
and match it against today's date and see if the difference is less than 24 hours.
I've researched a lot and this solution makes sense:
convert this date to epoch, get today's date in epoch and just find the diff for 24 hours in seconds.
Now the question is how do I get these two dates in epoch?
Newbie at Perl especially where this dates bit is concerned. So any and all help is appreciated.
Thanx!
Erum
What I need to do is take a date from an RSS feed (this part is done), which is in this format:
Sat, 01 Jul 2006 10:46:09 +0000
and match it against today's date and see if the difference is less than 24 hours.
I've researched a lot and this solution makes sense:
convert this date to epoch, get today's date in epoch and just find the diff for 24 hours in seconds.
Now the question is how do I get these two dates in epoch?
Newbie at Perl especially where this dates bit is concerned. So any and all help is appreciated.
Thanx!
Erum