Help:Feed format

From semantic-mediawiki.org
Jump to: navigation, search
Feed format
Export results as RSS and Atom feed
Available languages
deen
Scenarios, examples, demos
Example: RSS news feed, Atom news feed
Image collection
Further Information
Provided by: Semantic MediaWiki
Added: 1.8.0
Removed: still supported
Requirements: none
Format name: feed
Enabled by default: 
Indicates whether the result format is enabled by default upon installation of the respective extension.
Yes
Authors: James Hong Kong
Categories: export · feed · xml
Group:
Class: SMWFeedResultPrinter, SMWExportPrinter
Table of Contents

↓ INFO ↓

The result format feed allows to export results as RSS and Atom feed format using the MediaWiki's export mechanisms. The default feed type is set to rss which can be changed using parameter |type=atom.

Please be aware, that the raw feed output is designed to be displayed in a syndication news reader and not optimized for the display in a web browser.

Parameters

General

Parameter Type Default Description
source text empty Alternative query source
limit whole number 50 The maximum number of results to return
offset whole number 0 The offset of the first result
link text all Show values as links
sort list of texts empty Property to sort the query by
order list of texts empty Order of the query sort
headers text show Display the headers/property names
mainlabel text no The label to give to the main page name
intro text empty The text to display before the query results, if there are any
outro text empty The text to display after the query results, if there are any
searchlabel text RSS Text for continuing the search
default text empty The text to display if there are no query results

Format specific

Parameter Aliases Type Default Description
type
text rss Feed type
title rsstitle text empty The text to be used as the title of the feed
description rssdescription text empty The text to be used as the description of the feed
page
text none Page content to be displayed with the feed

Customization

Starting with SMW 1.9.0 it is possible to add a linked icon to the searchlabel of an inline query. After you add the following code to your MediaWiki:Common.js page, a standard RSS feed icon will appear for all SMW RSS/Atom generated links (see also Searchlabel and further results).

/**
 * Additional linked icon for the searchlabel of result format "feed"
 *
 * @since 1.9.0
 *
 * @rev 1
 * @author mwjames
 */

$( '.smw-feed-furtherresults > a' ).addClass( 'feedlink' );

Examples



This documentation page applies to all SMW versions from 1.8.0 to the most current version.
      Other languages: de

Help:Feed format en 1.8.0