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 8278495
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T09:02:11+00:00 2026-06-08T09:02:11+00:00

In the http://feeds.feedburner.com/rb286 , there are many images. However, when i convert it into

  • 0

In the http://feeds.feedburner.com/rb286, there are many images. However, when i convert it into and xml object with simplXmlElement, i’m not able to see the images.My code:

if (function_exists("curl_init")){
$ch=curl_init();
curl_setopt($ch,CURLOPT_URL,"http://feeds.feedburner.com/rb286");
curl_setopt($ch,CURLOPT_RETURNTRANSFER,1);
$data=curl_exec($ch);
curl_close($ch);
//print_r($data);   //here i'm able to see the images
     $doc=new SimpleXmlElement($data);
     print_r($doc);   //here i'm not able to see the images
  }

Can someone tell me on how can I access the images after converting to xml object? thank you.

  • 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-06-08T09:02:15+00:00Added an answer on June 8, 2026 at 9:02 am

    You will have to iterate trough the <content:encoded> tags of the individual <items> in the <channel> main tag. I would use the xpath method to select the tags. Once you get the element you want you can grep the <img> out of them with string manipulation tools like preg_match_all:

    Edit: added more refined image tag matching, that excludes ads from feedburner and other cdns.

    $xml = simplexml_load_string(file_get_contents("http://feeds.feedburner.com/rb286"));
    
    foreach ($xml->xpath('//item/content:encoded') as $desc) {
        preg_match_all('!(?<imgs><img.+?src=[\'"].*?http://feeds.feedburner.com.+?[\'"].+?>)!m', $desc, $>
    
        foreach ($m['imgs'] as $img) {
            print $img;
        }
    }
    

    The <content:encoded> tag is namespaced, so if you want to use simplexml’s built in property mapping, you have to deal with it like this:

    // obtain simplexml object of the feed as before
    foreach ($xml->channel->item as $item) {
        $namespaces = $item->getNameSpaces(true);
        $content = $item->children($namespaces['content']);
        print $content->encoded; // use it howevery you want
    }
    

    You can read more from the xpath query language here.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a set of urls for example http://t3.gstatic.com/images?q=tbn:ANd9GcRfLZhH0jpyUJxGtsiHcldUPiNQsosLdR9xgcYqVWyRWGYS4qtt http://feeds.feedburner.com/~r/DrudgeReportFeed/~4/zSLWG4ybmjw I want to remove
I need to scrape an xml file from http://feeds.feedburner.com/Torrentfreak for its links and description.
I'm having trouble finding a regular expression that matches the following String. Korben;http://feeds.feedburner.com/KorbensBlog-UpgradeYourMind?format=xml;1 One
$fp = fopen(http://feeds.reuters.com/Reuters/PoliticsNews?format=xml,r) or die(Error reading RSS data.); The above coding working correctly in
My XML Feed looks like this http://tinyurl.com/6wc6fel Not sure how to read the data
XDocument coordinates = XDocument.Load(http://feeds.feedburner.com/TechCrunch); System.IO.StreamWriter StreamWriter1 = new System.IO.StreamWriter(DestFilePath); foreach (var coordinate in coordinates.Descendants(guid))
I am trying to parse the contents of http://feeds.feedburner.com/riabiz using XDocument.Parse(string) (because it gets
I'm making a simple rss reader for the iPhone. The feed ( http://feeds.feedburner.com/foksuk/gLTI )
$rssfeed = https://feedburner.google.com/api/awareness/1.0/GetFeedData?uri=tutorialsbucket; $twitter = http://twitter.com/users/show.xml?screen_name=tutorialsbucket; function followers($arg1, $arg2) { $url = array($arg1, $arg2);
I want to parse information in: http://feeds.informationweek.com/infoweek/news http://feeds.news.com.au/public/rss/2.0/fs_breaking_news_13.xml http://rss.cnn.com/rss/cnn_topstories.rss using php. And save the

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.