}
/**
- * This will be called immediately after the <body> tag. Split into
+ * This will be called immediately after the "<body>" tag. Split into
* two functions to make it easier to subclass.
* @return string
*/
}
/**
- * This gets called shortly before the </body> tag.
- * @return String HTML to be put before </body>
+ * This gets called shortly before the "</body>" tag.
+ * @return String HTML to be put before "</body>"
*/
function afterContent() {
return $this->doAfterContent();
if ( $wgOut->isArticleRelated() ) {
if ( $title->getNamespace() == NS_FILE ) {
- $name = $title->getDBkey();
$image = wfFindFile( $title );
if ( $image ) {
- $link = htmlspecialchars( $image->getURL() );
- $style = Linker::getInternalLinkAttributes( $link, $name );
- $s[] = "<a href=\"{$link}\"{$style}>{$name}</a>";
+ $href = $image->getURL();
+ $s[] = Html::element( 'a', array( 'href' => $href,
+ 'title' => $href ), $title->getText() );
+
}
}
}
$title = $this->getSkin()->getTitle();
if ( $wgOut->isArticleRelated() ) {
- if ( $title->userIsWatching() ) {
+ if ( $wgUser->isWatched( $title ) ) {
$text = wfMsg( 'unwatchthispage' );
$query = array(
'action' => 'unwatch',