I’m trying to get my account’s time line and display it. I’m using Abraham Williams authentication library. The program now displays the tweets, but I cannot figure out how to get the corresponding images. I looked in Twitter’s documentation and it has that information being return in the xml file. I’m using library which returns an array of objects. I’m iterating through each one and calling the text method which displays the text of the tweet. I cannot find any methods in the object that would pertain to each image’s url.
$home_timeline = $oauth->get('statuses/home_timeline',array('count' => 40));
// print_r($home_timeline);
foreach ($home_timeline as $status)
// can get the text but not the image url
echo "Tweet: $status->text";
If you are looking to display the profile images of the users’ posting the tweets, then grab the
profile_image_urlproperty from each embeddeduserobject within thestatusobjects, like so: