Questions tagged [simplepie]

SimplePie is a PHP library intended to make it ridiculously easy for people to manage RSS and Atom feeds.

SimplePie is:

  • A code library, written in PHP, intended to make it ridiculously easy for people to manage RSS and Atom feeds.

  • An easy to use API that handles all of the dirty work when it comes to fetching, caching, parsing, normalizing data structures between RSS and Atom formats, handling character encoding translation, and sanitizing the resulting data.

  • Free (i.e. no cost) open-source software, with a license more liberal than the GPL (BSD-licensed), that was built and improved over the course of years by people who have a passion for good software that makes people's lives easier.

  • Well documented with a complete API reference, tutorials and screencasts for popularly requested uses, and details about the inner workings of the library.

  • Always looking for more people to contribute to the project in terms of code, patches, support, and evangelism.

  • A solution where we've worked very hard to keep the bar as low as possible for people who want to use it, but at the same time you MUST have a fundamental grasp of the PHP language. If you don't know PHP, and are interested in getting a handle on the basics, we recommend PHP 101: PHP For the Absolute Beginner (begin with parts 1-3, then move onto parts 4-7 making sure you actually understand them).

SimplePie is not:

  • A magical solution that will just "do it for you."

  • A copy-paste, "no code required" solution.

  • A full-blown feed aggregator like Google Reader, NewsGator Online, Bloglines, and the like.

If you don't know PHP, or are not willing to learn PHP, SimplePie is not the right solution for you.

However, SimplePie integrates well with a variety of blogging systems, wikis, forums, and code frameworks. Many of these third-party software packages are more end-user focused, and require less (if any) actual programming. Check out our SimplePie Plugins and Integration page to see if SimplePie integrates with software you already use, in a way that doesn't require much programming (if at all).

296 questions
2
votes
1 answer

Best Practice for Skipping Duplicate Entries in MySQL

I have written a feed aggregator before but am trying to optimize it a bit. In the past, using simplepie (php class) to parse the feeds, I have used the get_id() function for each feed item to return a hash (an md5 mix of link + title). I store this…
phirschybar
  • 8,357
  • 12
  • 50
  • 66
2
votes
1 answer

Pulling from atom feed with simple pie

How can I get the title tag from the s:variant block below using simple pie? product_variants-96590662 Default Title 10.00 002
addedlovely
  • 3,076
  • 3
  • 22
  • 37
2
votes
1 answer

How to get the url from in a RSS feed using SimplePie

I'm trying to use SimplePie and PHP to grab the url value from the tag. An example of the RSS code is: Headline goes here https://sampledomain.com/index.html
2
votes
0 answers

PHP SimplePie throwing unserialize error on Feeds::make($feedUrl, 100)

When using SimplePie to get a list of the latest rss posts, the following code sometimes throws errors: $rssPosts = Feeds::make($rssFeedUrl, 100); PHP Notice: unserialize(): Error at offset 1177620 of 1179648 bytes in…
space_food_
  • 800
  • 1
  • 7
  • 23
2
votes
2 answers

How to use SimplePie with Laravel

I am using Laravel 5.2. I need to get RSS feeds using SimplePie, so I install the library through composer.json and now my vendor folder contains simplepie but when i run the following code this error shows: ErrorException in SimplePie.php line…
Bilal Hussain
  • 149
  • 1
  • 12
2
votes
1 answer

Does simplepie $itme->get_content() output need to be escaped when echoing to page?

I have a WordPress plugin that reads an RSS feed and outputs it to the browser in an admin page. In the plugin, it uses the standard feed.php template from WordPress (wp-includes/feed.php), which uses SimplePie to fetch the feed through…
2
votes
1 answer

SimplePie RSS Parsing - Take out words randomly from get_title?

I'm currently using SimplePie to parse RSS news feeds. I am successfully merging the feeds using an array, however what I need to do is return single words at random from the title, not just the whole title. Can this be done in PHP at all? I was…
biscuit_
  • 187
  • 1
  • 3
  • 16
2
votes
1 answer

Simplepie proxy support

Is there a simple solution to adding proxy settings on SimplePie? I've tried to look through resources online and there are a bunch of patches. None of them are really clear on what version of SimplePie they use. I am trying to build an RSS reader…
2
votes
5 answers

SimplePie not parsing flickr feed

I am trying to use SimplePie to pull a group pool flickr feed: $feed = new…
mn.
  • 41
  • 3
2
votes
1 answer

Simplepie - parsing multiple categories per item

Trying to parse rss feed with items that have multiple categories per item. The original file is an atom structured feed which I have parsed using simplexml and outputed certain elements as an rss feed. The multiple categories in the original atom…
user2982427
2
votes
1 answer

SimplePie: filter by item value and number of items

Basically I want to filter only items from various feeds that have a certain category using an of statement, and show only 6 items. I can do successfully either but not both at the same time. I'm trying to first filter the items depending on…
user2982427
2
votes
0 answers

SimplePie CRON job in Windows XAMPP

I am attempting to set up a CRON job on XAMPP in Windows but I am having some trouble. I have the timing set up so that it should run every 5 minutes, and this part works because I see my command prompt pop up every five minutes. This is the code…
Drizzit12
  • 169
  • 2
  • 19
2
votes
2 answers

simplexml_load_file vs Third party RSS parsing libraries.(PHP)

I wish to parse the RSS feed in PHP. I first found various third party libraries to do the same namely: Magpie and simplepie. But since RSS files are in XML format, PHP also has native functions of simplexml_load_file to parse a XML file. So why…
Bhumi Singhal
  • 8,063
  • 10
  • 50
  • 76
2
votes
3 answers

Using SimplePie feed parser in Laravel

I tried to use the SimplePie feed parser in Laravel. I pushed autoloader.php and library folder of SimplePie in the Laravel libraries folder, then I added a map for SimplePie in start.php // folder tree libraries/ …
reza abbasi
  • 75
  • 3
  • 7
2
votes
3 answers

PHP - special character (euro sign) not displayed correctly (RSS feed/SimplePie)

I am using SimplePie (v1.3.1) to display a RSS feed on a webpage. One of the titles contains a euro (€) sign and it is displayed as € on the page. When I use the SimplePie's demo on their website it is displayed correctly, so it should be no…
4ice
  • 29
  • 1
  • 7
1 2
3
19 20