WOW RSSX is another PHP script that fetches either a single or multiple RSS Feeds and combines them to display on your website along with categories and dates. With added options, you can tailor the output to suit your needs. The difference between the recently published WOW RSS and WOW RSSX is that this script uses SimpleXML and WOW RSS uses cURL to fetch the feeds and JSON to convert the feeds from a SimpleXML object to a PHP array.

Speed Tests

Using the following code testing function to measure the execution time and memory usage to fetch 50 latest articles from 3 URLs. WOW RSSX was slightly slower but also used less memory during the process.

Prerequisites

WOW RSSX has been tested on PHP 5.6 and 7.03. Please get in touch if you require help.

Download

Simply download, extract and place it in on your PHP enabled web server.
Version 1.0 Released- 5th February 2018 Download WOW RSSX

How to Use

Once installed on your server you need to include the script in your PHP page.

Now we need to create a new instance of the class:

WowMultiXML take 4 arguments.

$urls

(Array|String) Required The URL(s) of the feeds you want to fetch.

$maxitems

(String|Int) Required The number of feeds you want to display.

$date_format

(String) Required The date format you want to display. – See http://php.net/manual/en/function.date.php An empty string will remove all dates from the output.

$sort_feed

(Array|Bool) Required The order in which you want to sort your feeds. Defaults to newest first if true is set.

Examples -Single Feeds

To display a single feed with the latest 10 items sorted with newest at the top and the date format  Jan 18

The same can also be achieved by the following

Display’s a single feed with 20 items sorted with oldest at the top and the date format  1-18-18

To display 2 single feeds with different options

Examples – Multiple Feeds Combined

Displays latest 50 items from 3 Combined Feeds with the date format 18 January 2018, sorted by newest first

This final example displays the latest 10 items from 3 Combined Feeds with the no date format, sorted by newest first

Styling Your Feeds

You can optimise the style of your feeds easily using CSS.  I have therefore included a CSS file in the download for your reference. The classes to edit are:

Further Improvements

Furthermore, if you would like to suggest an improvement to the code or request a new feature then please do get in touch. Although the code has been tested quite thoroughly it shouldn’t contain any bugs. Please report them if you do come across any.  Please remember that RSS is quite limited and in order for the script to work you have to have a valid RSS feed(s).

Sources

PHP Date Function