Extension:RSSPie

From Gamepedia Help Wiki
Jump to: navigation, search

The RSSPie extension fetches and displays RSS feeds on a wiki page using a simple tagging format.

Usage[edit | edit source]

Each RSS feed must use its own set of [rss] element tags. There are optional parameters available for the rss opening tag.

Parameters in the RSS tag
Attribute Description
itemTemplate="PageName" Default: Mediawiki:Rss_item_template
 Item template is used to define the display template for individual items in a feed.  It requires a complete page name including namespace if needed.
max="X" Default: 5
 Show only X number of items from a feed.
sort="newest" Sort direction for feed items. Sorts newest first by default and can be set to oldest.
descriptionLength="200" Default: 200
 Truncates long descriptions automatically to the specified character length.
dateFormat="Y/m/d H:i" Default: Y/m/d H:i
 Formats the date using PHP formatting guidelines.  Please see the PHP date documentation for formatting information.
filterIn="example,words" Default: (None)
 Comma delimited list of search words to filter into the display.  If the item in the feed contains any of the word(s) the item will be shown.
filterOut="example,words" Default: (None)
 Comma delimited list of search words to filter out of the display.  If the item in the feed contains any of the word(s) the item will be hidden.  Any feed items that get caught by filterOut will hide regardless if they get caught by the filterIn parameter.

Example[edit | edit source]

This example displays a feed from Gampedia's home page with a maximum of six items displayed.

<rss max="6">https://www.gamepedia.com/news.rss</rss>

Take Your Toy Ships Into Digital Space in Starlink: Battle for Atlas - 2018/10/16 15:00

Toys-to-life games, games that have both a digital and physical components, had quite a moment earlier in the decade. After the closure of the studio that made Disney Infinity a couple of years ago, t...

Weekly Official Wiki Roundup: CardLife, Yuppie Psycho, Outpost Zero, and More! - 2018/10/12 15:00

Guess what, Gamepedia readers! Spookiness continues to descend upon us, and to that end we've got some scary good Official Wikis to share with you this week! Whether you're into survival games or surv...

Craft Your Own Corrugated Adventures in CardLife - 2018/10/09 17:00

Open-world survival is one of the most iterative genres in video games. There's always a new way to collect, craft, and create — and a new way to present it all. Enter CardLife, by Freejam (Robocraf...

Weekly Official Wiki Roundup: Torchlight Frontiers, Spellwake, and Green Hell - 2018/10/05 16:00

Things are getting spooky around here as we head into our first Weekly Official Wiki Roundup at Gamepedia for October! What kind of cool fall shenanigans are you getting into? Are you looking forward...

Automate Sci Fi Chaos in Nimbatus - 2018/10/02 16:00

Space is the final frontier for several reasons. Primarily it's because there are floating chunks of rock out there holding really neat space elements that would be much more useful not buried in thei...

Weekly Official Roundup: Mavericks: Proving Grounds, Stoneshard, and More! - 2018/09/28 15:00

It's officially fall, and we're here to welcome a series of new games to the Gamepedia Official Wiki collection! Are you kicking back and relaxing while welcoming that chill in the air? Sit back, grab...


Whitelisting Feeds[edit | edit source]

Whitelisting RSS feeds is controlled through the protected Mediawiki:Rss_Whitelist page. Simply insert one filter per line. A fully qualified URL may be entered or a partial URL using * wildcards. Adding * to its own line will whitelist all URLs.

https://www.gamepedia.com/news.rss
*/news.rss
https://www.gamepedia.com/*.rss

Template for items in feeds[edit | edit source]

NOTE:
Prof hydra.svg Editing the item template is not required, but allows customization on how the information is displayed.

The template parser will substitute five pieces of information for each feed item as needed. {{{link}}} - The URL

{{{title}}} - Item Title

{{{author}}} - Author's Name

{{{date}}} - Epoch Date(Note: Display formatting is handled by Javascript in the browser.)

{{{description}}} - Full description or summarized content.


Default Mediawiki:Rss_item_template template:

<div class='rss_item'>
'''<span class='plainlinks'>[{{{link}}} {{{title}}}]</span> - {{{author}}} - <span class='date_epoch'>{{{date}}}</span>'''
: {{{description}}}
</div>

Configuration Settings[edit | edit source]

Variable Default Value Description
$rpCacheDuration Default: 3600 seconds (One Hour) Cache feed information for the specified amount of seconds. Note: Very short durations will increase server load and the number of requests made to the remote host.

Migration from Extension:RSS[edit | edit source]

  • The date attribute was renamed to dateFormat. Please make sure to update the format to a PHP date compatible format.
  • The template attribute was renamed to itemTemplate and is the only template that needs to be edited. Simply copying the contents of Mediawiki:Rss-item to Mediawiki:Rss_item_template should suffice.
Promotional Content