r53150 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r53149‎ | r53150 | r53151 >
Date:23:32, 12 July 2009
Author:rememberthedot
Status:ok
Tags:
Comment:
Removed repetition of URIs in the title attributes (tooltips) of external links. Web browsers typically display the target URIs of links in the status bar, making repeating the URIs in tooltips redundant. Some browsers, like Opera, can be configured to display the URIs in tooltips instead of the status bar without the web page having to supply title attributes at all.

As part of this process, I refactored some of Linker.php and removed an unused parameter from getExternalLinkAttributes.
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/Linker.php (modified) (history)
  • /trunk/phase3/includes/Skin.php (modified) (history)
  • /trunk/phase3/includes/parser/Parser.php (modified) (history)
  • /trunk/phase3/maintenance/parserTests.txt (modified) (history)

Diff [purge]

Index: trunk/phase3/maintenance/parserTests.txt
@@ -441,7 +441,7 @@
442442 !! input
443443 ; http://example.com/ : definition
444444 !! result
445 -<dl><dt> <a href="http://example.com/" class="external free" title="http://example.com/" rel="nofollow">http://example.com/</a>&nbsp;</dt><dd> definition
 445+<dl><dt> <a href="http://example.com/" class="external free" rel="nofollow">http://example.com/</a>&nbsp;</dt><dd> definition
446446 </dd></dl>
447447
448448 !! end
@@ -451,7 +451,7 @@
452452 !! input
453453 ;[http://www.example.com/ Example]:Something about it
454454 !! result
455 -<dl><dt><a href="http://www.example.com/" class="external text" title="http://www.example.com/" rel="nofollow">Example</a></dt><dd>Something about it
 455+<dl><dt><a href="http://www.example.com/" class="external text" rel="nofollow">Example</a></dt><dd>Something about it
456456 </dd></dl>
457457
458458 !! end
@@ -472,7 +472,7 @@
473473 !! input
474474 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
475475 !! result
476 -<dl><dt> <a href="news:alt.wikipedia.rox" class="external free" title="news:alt.wikipedia.rox" rel="nofollow">news:alt.wikipedia.rox</a></dt><dd> This isn't even a real newsgroup!
 476+<dl><dt> <a href="news:alt.wikipedia.rox" class="external free" rel="nofollow">news:alt.wikipedia.rox</a></dt><dd> This isn't even a real newsgroup!
477477 </dd></dl>
478478
479479 !! end
@@ -482,7 +482,7 @@
483483 !! input
484484 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
485485 !! result
486 -<dl><dt> <a href="news:alt.wikipedia.rox" class="external free" title="news:alt.wikipedia.rox" rel="nofollow">news:alt.wikipedia.rox</a> -- don't crash or enter an infinite loop
 486+<dl><dt> <a href="news:alt.wikipedia.rox" class="external free" rel="nofollow">news:alt.wikipedia.rox</a> -- don't crash or enter an infinite loop
487487 </dt></dl>
488488
489489 !! end
@@ -492,7 +492,7 @@
493493 !! input
494494 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
495495 !! result
496 -<dl><dt> <a href="http://www.wikipedia2.org/" class="external text" title="http://www.wikipedia2.org/" rel="nofollow">Wikipedia&nbsp;: The Next Generation</a></dt><dd> OK, I made that up
 496+<dl><dt> <a href="http://www.wikipedia2.org/" class="external text" rel="nofollow">Wikipedia&nbsp;: The Next Generation</a></dt><dd> OK, I made that up
497497 </dd></dl>
498498
499499 !! end
@@ -527,7 +527,7 @@
528528 !! input
529529 Non-bracketed: http://example.com
530530 !! result
531 -<p>Non-bracketed: <a href="http://example.com" class="external free" title="http://example.com" rel="nofollow">http://example.com</a>
 531+<p>Non-bracketed: <a href="http://example.com" class="external free" rel="nofollow">http://example.com</a>
532532 </p>
533533 !! end
534534
@@ -538,9 +538,9 @@
539539 Numbered: [http://example.net]
540540 Numbered: [http://example.com]
541541 !! result
542 -<p>Numbered: <a href="http://example.com" class="external autonumber" title="http://example.com" rel="nofollow">[1]</a>
543 -Numbered: <a href="http://example.net" class="external autonumber" title="http://example.net" rel="nofollow">[2]</a>
544 -Numbered: <a href="http://example.com" class="external autonumber" title="http://example.com" rel="nofollow">[3]</a>
 542+<p>Numbered: <a href="http://example.com" class="external autonumber" rel="nofollow">[1]</a>
 543+Numbered: <a href="http://example.net" class="external autonumber" rel="nofollow">[2]</a>
 544+Numbered: <a href="http://example.com" class="external autonumber" rel="nofollow">[3]</a>
545545 </p>
546546 !!end
547547
@@ -549,7 +549,7 @@
550550 !! input
551551 Specified text: [http://example.com link]
552552 !! result
553 -<p>Specified text: <a href="http://example.com" class="external text" title="http://example.com" rel="nofollow">link</a>
 553+<p>Specified text: <a href="http://example.com" class="external text" rel="nofollow">link</a>
554554 </p>
555555 !!end
556556
@@ -558,7 +558,7 @@
559559 !! input
560560 Linktrails should not work for external links: [http://example.com link]s
561561 !! result
562 -<p>Linktrails should not work for external links: <a href="http://example.com" class="external text" title="http://example.com" rel="nofollow">link</a>s
 562+<p>Linktrails should not work for external links: <a href="http://example.com" class="external text" rel="nofollow">link</a>s
563563 </p>
564564 !! end
565565
@@ -567,7 +567,7 @@
568568 !! input
569569 http://example.com/1$2345
570570 !! result
571 -<p><a href="http://example.com/1$2345" class="external free" title="http://example.com/1$2345" rel="nofollow">http://example.com/1$2345</a>
 571+<p><a href="http://example.com/1$2345" class="external free" rel="nofollow">http://example.com/1$2345</a>
572572 </p>
573573 !! end
574574
@@ -576,7 +576,7 @@
577577 !! input
578578 [http://example.com/1$2345]
579579 !! result
580 -<p><a href="http://example.com/1$2345" class="external autonumber" title="http://example.com/1$2345" rel="nofollow">[1]</a>
 580+<p><a href="http://example.com/1$2345" class="external autonumber" rel="nofollow">[1]</a>
581581 </p>
582582 !!end
583583
@@ -585,7 +585,7 @@
586586 !! input
587587 http://example.com/1[2345
588588 !! result
589 -<p><a href="http://example.com/1" class="external free" title="http://example.com/1" rel="nofollow">http://example.com/1</a>[2345
 589+<p><a href="http://example.com/1" class="external free" rel="nofollow">http://example.com/1</a>[2345
590590 </p>
591591 !! end
592592
@@ -594,7 +594,7 @@
595595 !! input
596596 [http://example.com/1[2345]
597597 !! result
598 -<p><a href="http://example.com/1" class="external text" title="http://example.com/1" rel="nofollow">[2345</a>
 598+<p><a href="http://example.com/1" class="external text" rel="nofollow">[2345</a>
599599 </p>
600600 !!end
601601
@@ -603,7 +603,7 @@
604604 !!input
605605 [http://example.com/ <nowiki>''example site''</nowiki>]
606606 !! result
607 -<p><a href="http://example.com/" class="external text" title="http://example.com/" rel="nofollow">''example site''</a>
 607+<p><a href="http://example.com/" class="external text" rel="nofollow">''example site''</a>
608608 </p>
609609 !! end
610610
@@ -613,7 +613,7 @@
614614 [http://example.com/ first
615615 second]
616616 !! result
617 -<p>[<a href="http://example.com/" class="external free" title="http://example.com/" rel="nofollow">http://example.com/</a> first
 617+<p>[<a href="http://example.com/" class="external free" rel="nofollow">http://example.com/</a> first
618618 second]
619619 </p>
620620 !!end
@@ -641,7 +641,7 @@
642642 !! input
643643 Link to non-http image, no img tag: ftp://example.com/test.jpg
644644 !! result
645 -<p>Link to non-http image, no img tag: <a href="ftp://example.com/test.jpg" class="external free" title="ftp://example.com/test.jpg" rel="nofollow">ftp://example.com/test.jpg</a>
 645+<p>Link to non-http image, no img tag: <a href="ftp://example.com/test.jpg" class="external free" rel="nofollow">ftp://example.com/test.jpg</a>
646646 </p>
647647 !! end
648648
@@ -650,7 +650,7 @@
651651 !! input
652652 Terminating separator: http://example.com/thing,
653653 !! result
654 -<p>Terminating separator: <a href="http://example.com/thing" class="external free" title="http://example.com/thing" rel="nofollow">http://example.com/thing</a>,
 654+<p>Terminating separator: <a href="http://example.com/thing" class="external free" rel="nofollow">http://example.com/thing</a>,
655655 </p>
656656 !! end
657657
@@ -659,7 +659,7 @@
660660 !! input
661661 Intervening separator: http://example.com/1,2,3
662662 !! result
663 -<p>Intervening separator: <a href="http://example.com/1,2,3" class="external free" title="http://example.com/1,2,3" rel="nofollow">http://example.com/1,2,3</a>
 663+<p>Intervening separator: <a href="http://example.com/1,2,3" class="external free" rel="nofollow">http://example.com/1,2,3</a>
664664 </p>
665665 !! end
666666
@@ -668,7 +668,7 @@
669669 !! input
670670 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
671671 !! result
672 -<p>Old bug with URL in query: <a href="http://example.com/thing?url=http://example.com" class="external text" title="http://example.com/thing?url=http://example.com" rel="nofollow">link</a>
 672+<p>Old bug with URL in query: <a href="http://example.com/thing?url=http://example.com" class="external text" rel="nofollow">link</a>
673673 </p>
674674 !! end
675675
@@ -677,7 +677,7 @@
678678 !! input
679679 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
680680 !! result
681 -<p>And again with mixed protocols: <a href="ftp://example.com?url=http://example.com" class="external text" title="ftp://example.com?url=http://example.com" rel="nofollow">link</a>
 681+<p>And again with mixed protocols: <a href="ftp://example.com?url=http://example.com" class="external text" rel="nofollow">link</a>
682682 </p>
683683 !!end
684684
@@ -686,7 +686,7 @@
687687 !! input
688688 URL in text: [http://example.com http://example.com]
689689 !! result
690 -<p>URL in text: <a href="http://example.com" class="external free" title="http://example.com" rel="nofollow">http://example.com</a>
 690+<p>URL in text: <a href="http://example.com" class="external free" rel="nofollow">http://example.com</a>
691691 </p>
692692 !! end
693693
@@ -695,7 +695,7 @@
696696 !! input
697697 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
698698 !! result
699 -<p>ja-style clickable images: <a href="http://example.com" class="external text" title="http://example.com" rel="nofollow"><img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" /></a>
 699+<p>ja-style clickable images: <a href="http://example.com" class="external text" rel="nofollow"><img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" /></a>
700700 </p>
701701 !!end
702702
@@ -704,7 +704,7 @@
705705 !! input
706706 Old &amp; use: http://x&y
707707 !! result
708 -<p>Old &amp; use: <a href="http://x&amp;y" class="external free" title="http://x&amp;y" rel="nofollow">http://x&amp;y</a>
 708+<p>Old &amp; use: <a href="http://x&amp;y" class="external free" rel="nofollow">http://x&amp;y</a>
709709 </p>
710710 !! end
711711
@@ -713,7 +713,7 @@
714714 !! input
715715 Old &amp; use: http://x&amp;y
716716 !! result
717 -<p>Old &amp; use: <a href="http://x&amp;y" class="external free" title="http://x&amp;y" rel="nofollow">http://x&amp;y</a>
 717+<p>Old &amp; use: <a href="http://x&amp;y" class="external free" rel="nofollow">http://x&amp;y</a>
718718 </p>
719719 !! end
720720
@@ -722,7 +722,7 @@
723723 !! input
724724 http://example.com/?foo&#61;bar
725725 !! result
726 -<p><a href="http://example.com/?foo=bar" class="external free" title="http://example.com/?foo=bar" rel="nofollow">http://example.com/?foo=bar</a>
 726+<p><a href="http://example.com/?foo=bar" class="external free" rel="nofollow">http://example.com/?foo=bar</a>
727727 </p>
728728 !! end
729729
@@ -731,7 +731,7 @@
732732 !! input
733733 Old &amp; use: [http://x&y]
734734 !! result
735 -<p>Old &amp; use: <a href="http://x&amp;y" class="external autonumber" title="http://x&amp;y" rel="nofollow">[1]</a>
 735+<p>Old &amp; use: <a href="http://x&amp;y" class="external autonumber" rel="nofollow">[1]</a>
736736 </p>
737737 !! end
738738
@@ -740,7 +740,7 @@
741741 !! input
742742 Old &amp; use: [http://x&amp;y]
743743 !! result
744 -<p>Old &amp; use: <a href="http://x&amp;y" class="external autonumber" title="http://x&amp;y" rel="nofollow">[1]</a>
 744+<p>Old &amp; use: <a href="http://x&amp;y" class="external autonumber" rel="nofollow">[1]</a>
745745 </p>
746746 !! end
747747
@@ -749,7 +749,7 @@
750750 !! input
751751 [http://example.com/?foo&#61;bar]
752752 !! result
753 -<p><a href="http://example.com/?foo=bar" class="external autonumber" title="http://example.com/?foo=bar" rel="nofollow">[1]</a>
 753+<p><a href="http://example.com/?foo=bar" class="external autonumber" rel="nofollow">[1]</a>
754754 </p>
755755 !! end
756756
@@ -758,7 +758,7 @@
759759 !! input
760760 [http://e&zwnj;xample.com/]
761761 !! result
762 -<p><a href="http://example.com/" class="external autonumber" title="http://example.com/" rel="nofollow">[1]</a>
 762+<p><a href="http://example.com/" class="external autonumber" rel="nofollow">[1]</a>
763763 </p>
764764 !! end
765765
@@ -767,7 +767,7 @@
768768 !! input
769769 http://e&zwnj;xample.com/
770770 !! result
771 -<p><a href="http://example.com/" class="external free" title="http://example.com/" rel="nofollow">http://example.com/</a>
 771+<p><a href="http://example.com/" class="external free" rel="nofollow">http://example.com/</a>
772772 </p>
773773 !! end
774774
@@ -776,7 +776,7 @@
777777 !! input
778778 http://www.jpeg.org
779779 !!result
780 -<p><a href="http://www.jpeg.org" class="external free" title="http://www.jpeg.org" rel="nofollow">http://www.jpeg.org</a>
 780+<p><a href="http://www.jpeg.org" class="external free" rel="nofollow">http://www.jpeg.org</a>
781781 </p>
782782 !! end
783783
@@ -785,7 +785,7 @@
786786 !! input
787787 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
788788 !! result
789 -<p><a href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp" class="external autonumber" title="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp" rel="nofollow">[1]</a>
 789+<p><a href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp" class="external autonumber" rel="nofollow">[1]</a>
790790 </p>
791791 !! end
792792
@@ -794,7 +794,7 @@
795795 !! input
796796 [http://www.example.com/foo http://www.example.com/bar]
797797 !! result
798 -<p><a href="http://www.example.com/foo" class="external text" title="http://www.example.com/foo" rel="nofollow">http://www.example.com/bar</a>
 798+<p><a href="http://www.example.com/foo" class="external text" rel="nofollow">http://www.example.com/bar</a>
799799 </p>
800800 !! end
801801
@@ -803,7 +803,7 @@
804804 !! input
805805 http://www.example.com/foo?=http://www.example.com/bar
806806 !! result
807 -<p><a href="http://www.example.com/foo?=http://www.example.com/bar" class="external free" title="http://www.example.com/foo?=http://www.example.com/bar" rel="nofollow">http://www.example.com/foo?=http://www.example.com/bar</a>
 807+<p><a href="http://www.example.com/foo?=http://www.example.com/bar" class="external free" rel="nofollow">http://www.example.com/foo?=http://www.example.com/bar</a>
808808 </p>
809809 !! end
810810
@@ -812,7 +812,7 @@
813813 !! input
814814 http://www.example.com/<hello>
815815 !! result
816 -<p><a href="http://www.example.com/" class="external free" title="http://www.example.com/" rel="nofollow">http://www.example.com/</a>&lt;hello&gt;
 816+<p><a href="http://www.example.com/" class="external free" rel="nofollow">http://www.example.com/</a>&lt;hello&gt;
817817 </p>
818818 !!end
819819
@@ -821,7 +821,7 @@
822822 !! input
823823 http://www.example.com/<b>html</b>
824824 !! result
825 -<p><a href="http://www.example.com/" class="external free" title="http://www.example.com/" rel="nofollow">http://www.example.com/</a><b>html</b>
 825+<p><a href="http://www.example.com/" class="external free" rel="nofollow">http://www.example.com/</a><b>html</b>
826826 </p>
827827 !!end
828828
@@ -830,7 +830,7 @@
831831 !! input
832832 [http://www.example.com/<hello> stuff]
833833 !! result
834 -<p><a href="http://www.example.com/" class="external text" title="http://www.example.com/" rel="nofollow">&lt;hello&gt; stuff</a>
 834+<p><a href="http://www.example.com/" class="external text" rel="nofollow">&lt;hello&gt; stuff</a>
835835 </p>
836836 !!end
837837
@@ -839,7 +839,7 @@
840840 !! input
841841 [http://www.example.com/<b>html</b> stuff]
842842 !! result
843 -<p><a href="http://www.example.com/" class="external text" title="http://www.example.com/" rel="nofollow"><b>html</b> stuff</a>
 843+<p><a href="http://www.example.com/" class="external text" rel="nofollow"><b>html</b> stuff</a>
844844 </p>
845845 !!end
846846
@@ -848,7 +848,7 @@
849849 !! input
850850 http://www.example.com/"hello"
851851 !! result
852 -<p><a href="http://www.example.com/" class="external free" title="http://www.example.com/" rel="nofollow">http://www.example.com/</a>"hello"
 852+<p><a href="http://www.example.com/" class="external free" rel="nofollow">http://www.example.com/</a>"hello"
853853 </p>
854854 !!end
855855
@@ -857,7 +857,7 @@
858858 !! input
859859 [http://www.example.com/"hello" stuff]
860860 !! result
861 -<p><a href="http://www.example.com/" class="external text" title="http://www.example.com/" rel="nofollow">"hello" stuff</a>
 861+<p><a href="http://www.example.com/" class="external text" rel="nofollow">"hello" stuff</a>
862862 </p>
863863 !!end
864864
@@ -869,7 +869,7 @@
870870 !! input
871871 [http://www.example.com test]
872872 !! result
873 -<p>[<a href="http://www.example.com" class="external free" title="http://www.example.com" rel="nofollow">http://www.example.com</a> test]
 873+<p>[<a href="http://www.example.com" class="external free" rel="nofollow">http://www.example.com</a> test]
874874 </p>
875875 !! end
876876
@@ -878,7 +878,7 @@
879879 !! input
880880 [http://www.example.com test]
881881 !! result
882 -<p><a href="http://www.example.com" class="external text" title="http://www.example.com" rel="nofollow">test</a>
 882+<p><a href="http://www.example.com" class="external text" rel="nofollow">test</a>
883883 </p>
884884 !! end
885885
@@ -887,7 +887,7 @@
888888 !! input
889889 [http://example.com [[wikilink]] embedded in ext link]
890890 !! result
891 -<p><a href="http://example.com" class="external text" title="http://example.com" rel="nofollow"></a><a href="https://www.mediawiki.org/index.php?title=Wikilink&amp;action=edit&amp;redlink=1" class="new" title="Wikilink (page does not exist)">wikilink</a><a href="http://example.com" class="external text" title="http://example.com" rel="nofollow"> embedded in ext link</a>
 891+<p><a href="http://example.com" class="external text" rel="nofollow"></a><a href="https://www.mediawiki.org/index.php?title=Wikilink&amp;action=edit&amp;redlink=1" class="new" title="Wikilink (page does not exist)">wikilink</a><a href="http://example.com" class="external text" rel="nofollow"> embedded in ext link</a>
892892 </p>
893893 !! end
894894
@@ -912,11 +912,11 @@
913913 ''Something [http://example.com mixed''''', even bold]'''
914914 '''''Now [http://example.com both''''']
915915 !! result
916 -<p><a href="http://example.com" class="external text" title="http://example.com" rel="nofollow"><i>text</i></a>
917 -<a href="http://example.com" class="external text" title="http://example.com" rel="nofollow"><b>text</b></a>
918 -<i>Something </i><a href="http://example.com" class="external text" title="http://example.com" rel="nofollow"><i>in italic</i></a>
919 -<i>Something </i><a href="http://example.com" class="external text" title="http://example.com" rel="nofollow"><i>mixed</i><b>, even bold</b></a>
920 -<i><b>Now </b></i><a href="http://example.com" class="external text" title="http://example.com" rel="nofollow"><i><b>both</b></i></a>
 916+<p><a href="http://example.com" class="external text" rel="nofollow"><i>text</i></a>
 917+<a href="http://example.com" class="external text" rel="nofollow"><b>text</b></a>
 918+<i>Something </i><a href="http://example.com" class="external text" rel="nofollow"><i>in italic</i></a>
 919+<i>Something </i><a href="http://example.com" class="external text" rel="nofollow"><i>mixed</i><b>, even bold</b></a>
 920+<i><b>Now </b></i><a href="http://example.com" class="external text" rel="nofollow"><i><b>both</b></i></a>
921921 </p>
922922 !! end
923923
@@ -926,7 +926,7 @@
927927 !! input
928928 http://www.example.com/?title=AT%26T
929929 !! result
930 -<p><a href="http://www.example.com/?title=AT%26T" class="external free" title="http://www.example.com/?title=AT%26T" rel="nofollow">http://www.example.com/?title=AT%26T</a>
 930+<p><a href="http://www.example.com/?title=AT%26T" class="external free" rel="nofollow">http://www.example.com/?title=AT%26T</a>
931931 </p>
932932 !! end
933933
@@ -935,7 +935,7 @@
936936 !! input
937937 http://www.example.com/?title=100%25_Bran
938938 !! result
939 -<p><a href="http://www.example.com/?title=100%25_Bran" class="external free" title="http://www.example.com/?title=100%25_Bran" rel="nofollow">http://www.example.com/?title=100%25_Bran</a>
 939+<p><a href="http://www.example.com/?title=100%25_Bran" class="external free" rel="nofollow">http://www.example.com/?title=100%25_Bran</a>
940940 </p>
941941 !! end
942942
@@ -944,7 +944,7 @@
945945 !! input
946946 http://www.example.com/?title=Ben-Hur_%281959_film%29
947947 !! result
948 -<p><a href="http://www.example.com/?title=Ben-Hur_%281959_film%29" class="external free" title="http://www.example.com/?title=Ben-Hur_%281959_film%29" rel="nofollow">http://www.example.com/?title=Ben-Hur_%281959_film%29</a>
 948+<p><a href="http://www.example.com/?title=Ben-Hur_%281959_film%29" class="external free" rel="nofollow">http://www.example.com/?title=Ben-Hur_%281959_film%29</a>
949949 </p>
950950 !! end
951951
@@ -954,7 +954,7 @@
955955 !! input
956956 [http://www.example.com/?title=AT%26T]
957957 !! result
958 -<p><a href="http://www.example.com/?title=AT%26T" class="external autonumber" title="http://www.example.com/?title=AT%26T" rel="nofollow">[1]</a>
 958+<p><a href="http://www.example.com/?title=AT%26T" class="external autonumber" rel="nofollow">[1]</a>
959959 </p>
960960 !! end
961961
@@ -963,7 +963,7 @@
964964 !! input
965965 [http://www.example.com/?title=100%25_Bran]
966966 !! result
967 -<p><a href="http://www.example.com/?title=100%25_Bran" class="external autonumber" title="http://www.example.com/?title=100%25_Bran" rel="nofollow">[1]</a>
 967+<p><a href="http://www.example.com/?title=100%25_Bran" class="external autonumber" rel="nofollow">[1]</a>
968968 </p>
969969 !! end
970970
@@ -972,7 +972,7 @@
973973 !! input
974974 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
975975 !! result
976 -<p><a href="http://www.example.com/?title=Ben-Hur_%281959_film%29" class="external autonumber" title="http://www.example.com/?title=Ben-Hur_%281959_film%29" rel="nofollow">[1]</a>
 976+<p><a href="http://www.example.com/?title=Ben-Hur_%281959_film%29" class="external autonumber" rel="nofollow">[1]</a>
977977 </p>
978978 !! end
979979
@@ -982,7 +982,7 @@
983983 !! input
984984 [http://www.example.com/?title=AT%26T link]
985985 !! result
986 -<p><a href="http://www.example.com/?title=AT%26T" class="external text" title="http://www.example.com/?title=AT%26T" rel="nofollow">link</a>
 986+<p><a href="http://www.example.com/?title=AT%26T" class="external text" rel="nofollow">link</a>
987987 </p>
988988 !! end
989989
@@ -991,7 +991,7 @@
992992 !! input
993993 [http://www.example.com/?title=100%25_Bran link]
994994 !! result
995 -<p><a href="http://www.example.com/?title=100%25_Bran" class="external text" title="http://www.example.com/?title=100%25_Bran" rel="nofollow">link</a>
 995+<p><a href="http://www.example.com/?title=100%25_Bran" class="external text" rel="nofollow">link</a>
996996 </p>
997997 !! end
998998
@@ -1000,7 +1000,7 @@
10011001 !! input
10021002 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
10031003 !! result
1004 -<p><a href="http://www.example.com/?title=Ben-Hur_%281959_film%29" class="external text" title="http://www.example.com/?title=Ben-Hur_%281959_film%29" rel="nofollow">link</a>
 1004+<p><a href="http://www.example.com/?title=Ben-Hur_%281959_film%29" class="external text" rel="nofollow">link</a>
10051005 </p>
10061006 !! end
10071007
@@ -1009,7 +1009,7 @@
10101010 !! input
10111011 Some [http://example.com/ pretty ''italics'' and stuff]!
10121012 !! result
1013 -<p>Some <a href="http://example.com/" class="external text" title="http://example.com/" rel="nofollow">pretty <i>italics</i> and stuff</a>!
 1013+<p>Some <a href="http://example.com/" class="external text" rel="nofollow">pretty <i>italics</i> and stuff</a>!
10141014 </p>
10151015 !! end
10161016
@@ -1018,7 +1018,7 @@
10191019 !! input
10201020 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
10211021 !! result
1022 -<p><i>Some </i><a href="http://example.com/" class="external text" title="http://example.com/" rel="nofollow"><i>pretty </i>italics<i> and stuff</i></a><i>!</i>
 1022+<p><i>Some </i><a href="http://example.com/" class="external text" rel="nofollow"><i>pretty </i>italics<i> and stuff</i></a><i>!</i>
10231023 </p>
10241024 !! end
10251025
@@ -1499,7 +1499,7 @@
15001500 !! input
15011501 [[http://www.example.com]]
15021502 !! result
1503 -<p>[<a href="http://www.example.com" class="external autonumber" title="http://www.example.com" rel="nofollow">[1]</a>]
 1503+<p>[<a href="http://www.example.com" class="external autonumber" rel="nofollow">[1]</a>]
15041504 </p>
15051505 !! end
15061506
@@ -1510,7 +1510,7 @@
15111511 # ----
15121512 # I'm changing it to match the current output--it arguably makes more
15131513 # sense in the light of the test above. Old expected result was:
1514 -#<p>Piped link to URL: <a href="https://www.mediawiki.org/index.php?title=Http://www.example.com&amp;action=edit" class="new" title="Http://www.example.com">an example URL</a>
 1514+#<p>Piped link to URL: <a href="https://www.mediawiki.org/index.php?title=Http://www.example.com&amp;action=edit" class="new">an example URL</a>
15151515 #</p>
15161516 # But I think this test is bordering on "garbage in, garbage out" anyway.
15171517 # -- wtm
@@ -1519,7 +1519,7 @@
15201520 !! input
15211521 Piped link to URL: [[http://www.example.com|an example URL]]
15221522 !! result
1523 -<p>Piped link to URL: [<a href="http://www.example.com|an" class="external text" title="http://www.example.com|an" rel="nofollow">example URL</a>]
 1523+<p>Piped link to URL: [<a href="http://www.example.com|an" class="external text" rel="nofollow">example URL</a>]
15241524 </p>
15251525 !! end
15261526
@@ -2030,7 +2030,7 @@
20312031 !! input
20322032 {{SERVER}}
20332033 !! result
2034 -<p><a href="http://localhost" class="external free" title="http://localhost" rel="nofollow">http://localhost</a>
 2034+<p><a href="http://localhost" class="external free" rel="nofollow">http://localhost</a>
20352035 </p>
20362036 !! end
20372037
@@ -2180,7 +2180,7 @@
21812181 !! input
21822182 RFC 822
21832183 !! result
2184 -<p><a href="http://tools.ietf.org/html/rfc822" class="external" title="http://tools.ietf.org/html/rfc822">RFC 822</a>
 2184+<p><a href="http://tools.ietf.org/html/rfc822" class="external">RFC 822</a>
21852185 </p>
21862186 !! end
21872187
@@ -2198,7 +2198,7 @@
21992199 !! input
22002200 PMID 1234
22012201 !! result
2202 -<p><a href="http://www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract" class="external" title="http://www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
 2202+<p><a href="http://www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract" class="external">PMID 1234</a>
22032203 </p>
22042204 !! end
22052205
@@ -3269,7 +3269,7 @@
32703270 !! input
32713271 [[Image:foobar.jpg|thumb|http://example.com]]
32723272 !! result
3273 -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="http://example.com" class="external free" title="http://example.com" rel="nofollow">http://example.com</a></div></div></div>
 3273+<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="http://example.com" class="external free" rel="nofollow">http://example.com</a></div></div></div>
32743274
32753275 !! end
32763276
@@ -3278,7 +3278,7 @@
32793279 !! input
32803280 [[Image:foobar.jpg|thumb|http://example.com|alt=Alteration]]
32813281 !! result
3282 -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Alteration" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="http://example.com" class="external free" title="http://example.com" rel="nofollow">http://example.com</a></div></div></div>
 3282+<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Alteration" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a href="http://example.com" class="external free" rel="nofollow">http://example.com</a></div></div></div>
32833283
32843284 !! end
32853285
@@ -3296,7 +3296,7 @@
32973297 !! input
32983298 [[Image:foobar.jpg|thumb|This is RFC 12354]]
32993299 !! result
3300 -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is <a href="http://tools.ietf.org/html/rfc12354" class="external" title="http://tools.ietf.org/html/rfc12354">RFC 12354</a></div></div></div>
 3300+<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This is <a href="http://tools.ietf.org/html/rfc12354" class="external">RFC 12354</a></div></div></div>
33013301
33023302 !! end
33033303
@@ -3305,7 +3305,7 @@
33063306 !! input
33073307 [[Image:foobar.jpg|thumb|Please mailto:nobody@example.com]]
33083308 !! result
3309 -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Please <a href="mailto:nobody@example.com" class="external free" title="mailto:nobody@example.com" rel="nofollow">mailto:nobody@example.com</a></div></div></div>
 3309+<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Please <a href="mailto:nobody@example.com" class="external free" rel="nofollow">mailto:nobody@example.com</a></div></div></div>
33103310
33113311 !! end
33123312
@@ -3419,7 +3419,7 @@
34203420 !! input
34213421 [[Image:Foobar.jpg|thumb|200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
34223422 !! result
3423 -<div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This caption has <a href="irc://example.net" class="external text" title="irc://example.net" rel="nofollow">irc</a> and <a href="https://example.com" class="external text" title="https://example.com" rel="nofollow">Secure</a> ext links in it.</div></div></div>
 3423+<div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>This caption has <a href="irc://example.net" class="external text" rel="nofollow">irc</a> and <a href="https://example.com" class="external text" rel="nofollow">Secure</a> ext links in it.</div></div></div>
34243424
34253425 !! end
34263426
@@ -3822,7 +3822,7 @@
38233823 !! input
38243824 http://example.com [[Image:foobar.jpg]]
38253825 !! result
3826 -<p><a href="http://example.com" class="external free" title="http://example.com" rel="nofollow">http://example.com</a> <a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
 3826+<p><a href="http://example.com" class="external free" rel="nofollow">http://example.com</a> <a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
38273827 </p>
38283828 !!end
38293829
@@ -3831,7 +3831,7 @@
38323832 !! input
38333833 http://example.com[[Image:foobar.jpg]]
38343834 !! result
3835 -<p><a href="http://example.com" class="external free" title="http://example.com" rel="nofollow">http://example.com</a><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
 3835+<p><a href="http://example.com" class="external free" rel="nofollow">http://example.com</a><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
38363836 </p>
38373837 !!end
38383838
@@ -3840,7 +3840,7 @@
38413841 !! input
38423842 http://en.wikinews.org/wiki/Wikinews:Workplace
38433843 !! result
3844 -<p><a href="http://en.wikinews.org/wiki/Wikinews:Workplace" class="external free" title="http://en.wikinews.org/wiki/Wikinews:Workplace" rel="nofollow">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
 3844+<p><a href="http://en.wikinews.org/wiki/Wikinews:Workplace" class="external free" rel="nofollow">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
38453845 </p>
38463846 !!end
38473847
@@ -4946,11 +4946,11 @@
49474947
49484948 mailto:inline@mail.tld
49494949 !! result
4950 -<p><a href="http://first/" class="external autonumber" title="http://first/" rel="nofollow">[1]</a> <a href="http://second" class="external autonumber" title="http://second" rel="nofollow">[2]</a> <a href="ftp://ftp" class="external autonumber" title="ftp://ftp" rel="nofollow">[3]</a>
4951 -</p><p><a href="ftp://inlineftp" class="external free" title="ftp://inlineftp" rel="nofollow">ftp://inlineftp</a>
4952 -</p><p><a href="mailto:enclosed@mail.tld" class="external text" title="mailto:enclosed@mail.tld" rel="nofollow">With target</a>
4953 -</p><p><a href="mailto:enclosed@mail.tld" class="external autonumber" title="mailto:enclosed@mail.tld" rel="nofollow">[4]</a>
4954 -</p><p><a href="mailto:inline@mail.tld" class="external free" title="mailto:inline@mail.tld" rel="nofollow">mailto:inline@mail.tld</a>
 4950+<p><a href="http://first/" class="external autonumber" rel="nofollow">[1]</a> <a href="http://second" class="external autonumber" rel="nofollow">[2]</a> <a href="ftp://ftp" class="external autonumber" rel="nofollow">[3]</a>
 4951+</p><p><a href="ftp://inlineftp" class="external free" rel="nofollow">ftp://inlineftp</a>
 4952+</p><p><a href="mailto:enclosed@mail.tld" class="external text" rel="nofollow">With target</a>
 4953+</p><p><a href="mailto:enclosed@mail.tld" class="external autonumber" rel="nofollow">[4]</a>
 4954+</p><p><a href="mailto:inline@mail.tld" class="external free" rel="nofollow">mailto:inline@mail.tld</a>
49554955 </p>
49564956 !! end
49574957
@@ -5030,7 +5030,7 @@
50315031 !! result
50325032 <table>
50335033 <tr>
5034 -<th> <a href="irc://{{ftp://a" class="external free" title="irc://{{ftp://a" rel="nofollow">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
 5034+<th> <a href="irc://{{ftp://a" class="external free" rel="nofollow">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
50355035 </th><td>
50365036 </td>
50375037 </tr>
@@ -5045,7 +5045,7 @@
50465046
50475047 {|
50485048 !!result
5049 -<p><a href="http://===r:::https://b" class="external free" title="http://===r:::https://b" rel="nofollow">http://===r:::https://b</a>
 5049+<p><a href="http://===r:::https://b" class="external free" rel="nofollow">http://===r:::https://b</a>
50505050 </p>
50515051 <table>
50525052 <tr><td></td></tr>
@@ -5109,7 +5109,7 @@
51105110 !! input
51115111 http://example.com <nowiki>junk</nowiki>
51125112 !! result
5113 -<p><a href="http://example.com" class="external free" title="http://example.com" rel="nofollow">http://example.com</a> junk
 5113+<p><a href="http://example.com" class="external free" rel="nofollow">http://example.com</a> junk
51145114 </p>
51155115 !!end
51165116
@@ -5119,7 +5119,7 @@
51205120 !! input
51215121 http://example.com<nowiki>junk</nowiki>
51225122 !! result
5123 -<p><a href="http://example.com" class="external free" title="http://example.com" rel="nofollow">http://example.com</a>junk
 5123+<p><a href="http://example.com" class="external free" rel="nofollow">http://example.com</a>junk
51245124 </p>
51255125 !!end
51265126
@@ -5129,7 +5129,7 @@
51305130 !! input
51315131 http://example.com<pre>junk</pre>
51325132 !! result
5133 -<a href="http://example.com" class="external free" title="http://example.com" rel="nofollow">http://example.com</a><pre>junk</pre>
 5133+<a href="http://example.com" class="external free" rel="nofollow">http://example.com</a><pre>junk</pre>
51345134
51355135 !!end
51365136
@@ -6137,7 +6137,7 @@
61386138 !! input
61396139 **irc://&#x0A;a
61406140 !! result
6141 -<ul><li><ul><li><a href="irc://%0Aa" class="external free" title="irc://%0Aa" rel="nofollow">irc://%0Aa</a>
 6141+<ul><li><ul><li><a href="irc://%0Aa" class="external free" rel="nofollow">irc://%0Aa</a>
61426142 </li></ul>
61436143 </li></ul>
61446144
@@ -6247,7 +6247,7 @@
62486248 <td><div class="gallerybox" style="width: 155px;">
62496249 <div style="height: 152px;">Image5.svg</div>
62506250 <div class="gallerytext">
6251 -<p><a href="http://///////" class="external free" title="http://///////" rel="nofollow">http://///////</a>
 6251+<p><a href="http://///////" class="external free" rel="nofollow">http://///////</a>
62526252 </p>
62536253 </div>
62546254 </div></td>
@@ -6312,7 +6312,7 @@
63136313 !! input
63146314 RFC RFC 1234
63156315 !! result
6316 -<p>RFC <a href="http://tools.ietf.org/html/rfc1234" class="external" title="http://tools.ietf.org/html/rfc1234">RFC 1234</a>
 6316+<p>RFC <a href="http://tools.ietf.org/html/rfc1234" class="external">RFC 1234</a>
63176317 </p>
63186318 !! end
63196319
@@ -6330,7 +6330,7 @@
63316331 !! input
63326332 RFC 983&#x20;987
63336333 !! result
6334 -<p><a href="http://tools.ietf.org/html/rfc983" class="external" title="http://tools.ietf.org/html/rfc983">RFC 983</a>&#x20;987
 6334+<p><a href="http://tools.ietf.org/html/rfc983" class="external">RFC 983</a>&#x20;987
63356335 </p>
63366336 !! end
63376337
@@ -6422,7 +6422,7 @@
64236423 !! input
64246424 [[image:Foobar.jpg|thumb|An [http://test/?param1=|left|&param2=|x external] URL]]
64256425 !! result
6426 -<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="An external URL" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>An <a href="http://test/?param1=|left|&amp;param2=|x" class="external text" title="http://test/?param1=|left|&amp;param2=|x" rel="nofollow">external</a> URL</div></div></div>
 6426+<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="image"><img alt="An external URL" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="https://www.mediawiki.org/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>An <a href="http://test/?param1=|left|&amp;param2=|x" class="external text" rel="nofollow">external</a> URL</div></div></div>
64276427
64286428 !!end
64296429
@@ -7238,7 +7238,7 @@
72397239 !! input
72407240 [http://en.wikipedia.org/]
72417241 !! result
7242 -<p><a href="http://en.wikipedia.org/" class="external autonumber" title="http://en.wikipedia.org/" rel="nofollow">[۱]</a>
 7242+<p><a href="http://en.wikipedia.org/" class="external autonumber" rel="nofollow">[۱]</a>
72437243 </p>
72447244 !! end
72457245
Index: trunk/phase3/includes/parser/Parser.php
@@ -961,7 +961,7 @@
962962 }
963963 $url = wfMsg( $urlmsg, $id);
964964 $sk = $this->mOptions->getSkin();
965 - $la = $sk->getExternalLinkAttributes( $url, $keyword.$id );
 965+ $la = $sk->getExternalLinkAttributes();
966966 return "<a href=\"{$url}\"{$la}>{$keyword} {$id}</a>";
967967 } elseif ( isset( $m[5] ) && $m[5] !== '' ) {
968968 # ISBN
Index: trunk/phase3/includes/Linker.php
@@ -21,13 +21,11 @@
2222 * Get the appropriate HTML attributes to add to the "a" element of an ex-
2323 * ternal link, as created by [wikisyntax].
2424 *
25 - * @param string $title The (unescaped) title text for the link
26 - * @param string $unused Unused
2725 * @param string $class The contents of the class attribute; if an empty
2826 * string is passed, which is the default value, defaults to 'external'.
2927 */
30 - function getExternalLinkAttributes( $title, $unused = null, $class='' ) {
31 - return $this->getLinkAttributesInternal( $title, $class, 'external' );
 28+ function getExternalLinkAttributes( $class = 'external' ) {
 29+ return $this->getLinkAttributesInternal( '', $class );
3230 }
3331
3432 /**
@@ -40,7 +38,7 @@
4139 * @param string $class The contents of the class attribute; if an empty
4240 * string is passed, which is the default value, defaults to 'external'.
4341 */
44 - function getInterwikiLinkAttributes( $title, $unused = null, $class='' ) {
 42+ function getInterwikiLinkAttributes( $title, $unused = null, $class = 'external' ) {
4543 global $wgContLang;
4644
4745 # FIXME: We have a whole bunch of handling here that doesn't happen in
@@ -49,7 +47,7 @@
5048 $title = $wgContLang->checkTitleEncoding( $title );
5149 $title = preg_replace( '/[\\x00-\\x1f]/', ' ', $title );
5250
53 - return $this->getLinkAttributesInternal( $title, $class, 'external' );
 51+ return $this->getLinkAttributesInternal( $title, $class );
5452 }
5553
5654 /**
@@ -87,14 +85,8 @@
8886 /**
8987 * Common code for getLinkAttributesX functions
9088 */
91 - private function getLinkAttributesInternal( $title, $class, $classDefault = false ) {
 89+ private function getLinkAttributesInternal( $title, $class ) {
9290 $title = htmlspecialchars( $title );
93 - if ( $class === '' and $classDefault !== false ) {
94 - # FIXME: Parameter defaults the hard way! We should just have
95 - # $class = 'external' or whatever as the default in the externally-
96 - # exposed functions, not $class = ''.
97 - $class = $classDefault;
98 - }
9991 $class = htmlspecialchars( $class );
10092 $r = '';
10193 if ( $class != '' ) {
@@ -749,7 +741,7 @@
750742 * hook play with them, *then* expand it all at once.
751743 */
752744 function makeExternalLink( $url, $text, $escape = true, $linktype = '', $attribs = array() ) {
753 - $attribsText = $this->getExternalLinkAttributes( $url, $text, 'external ' . $linktype );
 745+ $attribsText = $this->getExternalLinkAttributes( 'external ' . $linktype );
754746 $url = htmlspecialchars( $url );
755747 if( $escape ) {
756748 $text = htmlspecialchars( $text );
Index: trunk/phase3/includes/Skin.php
@@ -1844,7 +1844,7 @@
18451845 $text = $wgContLang->getLanguageName( $nt->getInterwiki() );
18461846
18471847 if ( '' == $text ) { $text = $l; }
1848 - $style = $this->getExternalLinkAttributes( $l, $text );
 1848+ $style = $this->getExternalLinkAttributes();
18491849 $s .= "<a href=\"{$url}\"{$style}>{$text}</a>";
18501850 }
18511851 if( $wgContLang->isRTL() ) $s .= '</span>';
Index: trunk/phase3/RELEASE-NOTES
@@ -119,13 +119,10 @@
120120 * Leading > is now syntax for <blockquote>.
121121 * (bug 19576) Moved id attribues from anchors accompanying section headers to
122122 the section headers themselves, removing the redundant anchor elements.
123 -* Removed name attribute from <a id="top"></a>.
124123 * Parser::setFunctionTagHook now can be used to add a new tag which is parsed at
125124 preprocesor level.
126125 * Added $wgShowArchiveThumbnails, allowing sysadmins to disable thumbnail
127126 display for old versions of images.
128 -* Remove five-year-old KHTMLFixes.css, which is unlikely to be relevant anymore
129 - and was causing problems.
130127
131128 === Bug fixes in 1.16 ===
132129
@@ -248,6 +245,10 @@
249246 * (bug 19602) PubMed Magic links now use updated NIH url
250247 * (bug 19637) externallinks have links to self
251248 * Don't load Opera 9.5 RTL fixes for Opera 9.6
 249+* Removed name attribute from <a id="top"></a>.
 250+* Remove five-year-old KHTMLFixes.css, which is unlikely to be relevant anymore
 251+ and was causing problems.
 252+* Removed repetition of URIs in the title attributes of external links.
252253
253254 == API changes in 1.16 ==
254255

Status & tagging log