Jump to content

[SOLVED] Extracting Atom Feed with PHP


Gaia

Recommended Posts

Hi,

 

I'm trying to extract data from an Atom feed using PHP.  I can get the title and published/updated date, but am having a hard time figuring out the path to the link="href" section of the Atom feed.

 

I have $xml->entry->link, but when I try to go any further it results in an empty result.  How do I finish the query to extract the link data?

 

Here is a print_r of $xml->entry->link

 

SimpleXMLElement Object
(
    [@attributes] => Array
        (
            [href] => /p/doulx
        )

)

 

I've never tried to extract data from an Atom feed before and am finding it difficult. Any tips would be great.

 

thanks.

Link to comment
https://forums.phpfreaks.com/topic/141873-solved-extracting-atom-feed-with-php/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.