r24657 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r24656‎ | r24657 | r24658 >
Date:17:01, 7 August 2007
Author:vyznev
Status:old
Tags:
Comment:
kluge to handle [[#Fragment]] links, should really fix getLocalURL() in Title.php to return an empty string in this case
Modified paths:
  • /trunk/extensions/ImageMap/ImageMap_body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/ImageMap/ImageMap_body.php
@@ -195,6 +195,10 @@
196196 if ( $wgNoFollowLinks ) {
197197 $attribs['rel'] = 'nofollow';
198198 }
 199+ } else if ( $title->getFragment() != '' && $title->getPrefixedDBkey() == '' ) {
 200+ # XXX: kluge to handle [[#Fragment]] links, should really fix getLocalURL()
 201+ # in Title.php to return an empty string in this case
 202+ $attribs['href'] = $title->getFragmentForURL();
199203 } else {
200204 $attribs['href'] = $title->escapeLocalURL() . $title->getFragmentForURL();
201205 }

Status & tagging log