Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 774269
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T19:06:15+00:00 2026-05-14T19:06:15+00:00

I have stores this object in an variable called results. How would i access

  • 0

I have stores this object in an variable called results. How would i access the profile_image_url for example.

Here is the return value with print_r:

stdClass Object ( 
  [results] => Array ( 
    [0] => stdClass Object ( 
      [profile_image_url] => http://a3.twimg.com/profile_images/685278639/twitter-logo_normal.jpg 
      [created_at] => Mon, 10 May 2010 11:29:44 +0000 
      [from_user] => BarclaysWealth 
      [metadata] => stdClass Object ( 
        [result_type] => recent ) 
      [to_user_id] => 
      [text] => RT @BarclaysStock: Investment ViewPoint - We take a look at what a hung parliament could mean for the UK economy http://bit.ly/OaYh7 
      [id] => 13721505359 
      [from_user_id] => 14895786 
      [geo] => 
      [iso_language_code] => en 
      [source] => <a href="http://twitter.com/">web</a>  ) 
    [1] => stdClass Object ( 
      [profile_image_url] => http://a1.twimg.com/profile_images/671523082/32fb0a8_normal.jpg 
      [created_at] => Fri, 07 May 2010 21:02:10 +0000 
      [from_user] => InfoFocus 
      [metadata] => stdClass Object ( 
        [result_type] => recent ) 
      [to_user_id] => 
      [text] => RT @BarclaysWealth: RT @BarclaysStock: Investment ViewPoint - We take a look at what a hung parliament could mean for the UK economy http://bit.ly/OaYh7 
      [id] => 13569384857 
      [from_user_id] => 85742792 
      [geo] => [iso_language_code] => en 
      [source] => <a href="http://www.hootsuite.com" rel="nofollow">HootSuite</a>  ) 
    [2] => stdClass Object ( 
      [profile_image_url] => http://a3.twimg.com/profile_images/685278639/twitter-logo_normal.jpg 
      [created_at] => Fri, 07 May 2010 20:59:20 +0000 
      [from_user] => BarclaysWealth 
      [metadata] => stdClass Object ( 
        [result_type] => recent ) 
      [to_user_id] => 
      [text] => RT @BarclaysStock: Investment ViewPoint - We take a look at what a hung parliament could mean for the UK economy http://bit.ly/OaYh7 
      [id] => 13569257933  
      [from_user_id] => 14895786  
      [geo] =>  
      [iso_language_code] => en  
      [source] => <a href="http://www.hootsuite.com" rel="nofollow">HootSuite</a>  )  
    [3] => stdClass Object (  
      [profile_image_url] => http://a1.twimg.com/profile_images/485934856/BD_Icon_Twitter_small_normal.gif  
      [created_at] => Fri, 07 May 2010 16:35:56 +0000  
      [from_user] => BARXdirect  
      [metadata] => stdClass Object (  
        [result_type] => recent )  
      [to_user_id] =>  
      [text] => RT @BarclaysStock: Investment ViewPoint - We take a look at what a hung parliament could mean for the UK economy http://bit.ly/OaYh7 
      [id] => 13557670463  
      [from_user_id] => 66715243  
      [geo] =>  
      [iso_language_code] => en  
      [source] => <a href="http://twitter.com/">web</a>  )  
    [4] => stdClass Object (  
      [profile_image_url] => http://a1.twimg.com/profile_images/431590520/BSL_icon_normal.gif 
      [created_at] => Fri, 07 May 2010 16:35:12 +0000  
      [from_user] => BarclaysStock  
      [metadata] => stdClass Object (  
        [result_type] => recent )  
      [to_user_id] =>  
      [text] => Investment ViewPoint - We take a look at what a hung parliament could mean for the UK economy http://bit.ly/OaYh7  
      [id] => 13557633799  
      [from_user_id] => 36238006  
      [geo] =>  
      [iso_language_code] => en  
      [source] => <a href="http://twitter.com/">web</a>  ) )  
  [max_id] => 13722716932 
  [since_id] => 0  
  [refresh_url] => ?since_id=13722716932&q=http%3A%2F%2Fbit.ly%2FOaYh7  
  [results_per_page] => 15  
  [page] => 1  
  [completed_in] => 0.026887  
  [query] => http%3A%2F%2Fbit.ly%2FOaYh7 ) 
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T19:06:16+00:00Added an answer on May 14, 2026 at 7:06 pm

    Here are some basic access examples:

    //get a single profile url
    echo $results->results[0]->profile_image_url;
    //or
    $tweet = $results->results[0];
    echo $tweet->profile_image_url;
    
    //get all the profile urls
    foreach($results->results as $tweets){
      echo $tweet->profile_image_url;
    }
    

    Of course the same basic concept applies to all the other properties, except (for this specific example data) the metadata property, which is an object.

    //to get result type
    echo $results->results[0]->metadata->result_type;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 371k
  • Answers 371k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Here's information on removing a changeset on CodePlex: http://codeplex.codeplex.com/wikipage?title=Removing%20a%20changeset%20from%20source%20control May 14, 2026 at 7:06 pm
  • Editorial Team
    Editorial Team added an answer You can use .nextUntil() and .wrapAll() to select and wrap… May 14, 2026 at 7:06 pm
  • Editorial Team
    Editorial Team added an answer Logic Studio Express is definitely a good option. It is… May 14, 2026 at 7:06 pm

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.