40 private function formatTime( $timestamp ) {
43 return gmdate(
'Y-m-d\TH:i:s', (
int)
wfTimestamp( TS_UNIX, $timestamp ) );
57 'feedID' => $this->getFeedId(),
60 'selfUrl' => $this->getSelfUrl(),
65 print $this->templateParser->processTemplate(
'AtomHeader', $templateParams );
76 private function getFeedId() {
77 return $this->getSelfUrl();
84 private function getSelfUrl() {
86 return htmlspecialchars(
$wgRequest->getFullRequestURL() );
94 $mimeType = MediaWikiServices::getInstance()->getMainConfig()
95 ->get( MainConfigNames::MimeType );
99 "uniqueID" => $item->getUniqueID(),
100 "title" => $item->getTitle(),
101 "mimeType" => $this->
xmlEncode( $mimeType ),
104 "description" => $item->getDescription(),
105 "author" => $item->getAuthor()
107 print $this->templateParser->processTemplate(
'AtomItem', $templateParams );
const MW_VERSION
The running version of MediaWiki.
wfTimestampNow()
Convenience function; returns MediaWiki timestamp for the present time.
wfExpandUrl( $url, $defaultProto=PROTO_CURRENT)
Expand a potentially local URL to a fully-qualified URL.
wfTimestamp( $outputtype=TS_UNIX, $ts=0)
Get a timestamp string in one of various formats.
outItem( $item)
Output a given item.
outFooter()
Outputs the footer for Atom 1.0 feed (basically '</feed>').
outHeader()
Outputs a basic header for Atom 1.0 feeds.
Class to support the outputting of syndication feeds in Atom and RSS format.
outXmlHeader()
Output the initial XML headers.
xmlEncodeNullable(?string $string)
Encode $string so that it can be safely embedded in a XML document, returning null if $string was nul...
getLanguage()
Get the language of this item.
getDescription()
Get the description of this item; already xml-encoded.
getTitle()
Get the title of this item; already xml-encoded.
xmlEncode( $string)
Encode $string so that it can be safely embedded in a XML document.
getUrlUnescaped()
Get the URL of this item without any escaping.
A class containing constants representing the names of configuration variables.
while(( $__line=Maintenance::readconsole()) !==false) print