[ Index ] |
PHP Cross Reference of MediaWiki-1.24.0 |
[Source view] [Print] [Project Stats]
Basic support for outputting syndication feeds in RSS, other formats. Contain a feed class as well as classes to build rss / atom ... feeds Available feeds are defined in Defines.php
File Size: | 424 lines (11 kb) |
Included or required: | 0 times |
Referenced: | 4 times |
Includes or requires: | 0 files |
FeedItem:: (15 methods):
__construct()
xmlEncode()
getUniqueId()
setUniqueId()
getTitle()
getUrl()
getDescription()
getLanguage()
getDate()
getAuthor()
getComments()
stripComment()
httpHeaders()
contentType()
outXmlHeader()
RSSFeed:: (4 methods):
formatTime()
outHeader()
outItem()
outFooter()
AtomFeed:: (6 methods):
formatTime()
outHeader()
getFeedId()
getSelfUrl()
outItem()
outFooter()
__construct( $title, $description, $url, $date = '', $author = '', $comments = '' ) X-Ref |
Constructor param: string|Title $title Item's title param: string $description param: string $url URL uniquely designating the item. param: string $date Item's date param: string $author Author's user name param: string $comments |
xmlEncode( $string ) X-Ref |
Encode $string so that it can be safely embedded in a XML document param: string $string String to encode return: string |
getUniqueId() X-Ref |
Get the unique id of this item return: string |
setUniqueId( $uniqueId, $rssIsPermalink = false ) X-Ref |
Set the unique id of an item param: string $uniqueId Unique id for the item param: bool $rssIsPermalink Set to true if the guid (unique id) is a permalink (RSS feeds only) |
getTitle() X-Ref |
Get the title of this item; already xml-encoded return: string |
getUrl() X-Ref |
Get the URL of this item; already xml-encoded return: string |
getDescription() X-Ref |
Get the description of this item; already xml-encoded return: string |
getLanguage() X-Ref |
Get the language of this item return: string |
getDate() X-Ref |
Get the date of this item return: string |
getAuthor() X-Ref |
Get the author of this item; already xml-encoded return: string |
getComments() X-Ref |
Get the comment of this item; already xml-encoded return: string |
stripComment( $text ) X-Ref |
Quickie hack... strip out wikilinks to more legible form from the comment. param: string $text Wikitext return: string |
httpHeaders() X-Ref |
Setup and send HTTP headers. Don't send any content; content might end up being cached and re-sent with these same headers later. This should be called from the outHeader() method, but can also be called separately. |
contentType() X-Ref |
Return an internet media type to be sent in the headers. return: string |
outXmlHeader() X-Ref |
Output the initial XML headers. |
formatTime( $ts ) X-Ref |
param: string|int $ts return: string |
outHeader() X-Ref |
Outputs a basic header for Atom 1.0 feeds. |
getFeedId() X-Ref |
Atom 1.0 requires a unique, opaque IRI as a unique identifier for every feed we create. For now just use the URL, but who can tell if that's right? If we put options on the feed, do we have to change the id? Maybe? Maybe not. return: string |
getSelfUrl() X-Ref |
Atom 1.0 requests a self-reference to the feed. return: string |
outItem( $item ) X-Ref |
Output a given item. param: FeedItem $item |
outFooter() X-Ref |
Outputs the footer for Atom 1.0 feed (basically '\</feed\>'). |
Generated: Fri Nov 28 14:03:12 2014 | Cross-referenced by PHPXref 0.7.1 |