Count the number of days from Twitter XML

Xtragicfever

New Member
I'm using the Twitter API to get my recent tweets from an XML file into my website.I already have the tweets displaying on my page but I can't get it to show how many days have passed since the displaying tweet.I've already tried some solutions answered here for the same problem but it didn't work for me.The Date and Time from the XML file are given as folows:\[code\]<statuses type="array"> <status> <created_at>Sat Mar 23 18:43:16 +0000 2013</created_at> </status></statuses>\[/code\]I'm retrieving the data like this:\[code\]<?php$xmldata = 'https://api.twitter.com/1/statuses/user_timeline.xml?screen_name=AblazeDigital';$open = fopen($xmldata, 'r');$content = stream_get_contents($open);fclose($open);$xml = new SimpleXMLElement($content);?><?php echo $xml->status[0]->created_at;?>\[/code\]How can I make a function with php the reads the follwing date "Sat Mar 23 18:43:16 +0000 2013" and tells how many days have passed to the present day?
 
Back
Top