1 # MediaWiki Parser test cases
2 # Some taken from http://meta.wikimedia.org/wiki/Parser_testing
3 # All (C) their respective authors and released under the GPL
5 # The syntax should be fairly self-explanatory.
7 # Currently supported test options:
8 # One of the following three:
10 # (default) generate HTML output
11 # pst apply pre-save transform
12 # msg apply message transform
14 # Plus any combination of these:
16 # cat add category links
17 # ill add inter-language links
18 # subpage enable subpages (disabled by default)
19 # noxml don't check for XML well formdness
20 # title=[[XXX]] run test using article title XXX
21 # language=XXX set content language to XXX for this test
22 # variant=XXX set the variant of language for this test (eg zh-tw)
23 # disabled do not run test
24 # parsoid parsoid-specific options (not run by PHP parser unless
25 # the test includes an html/php section)
26 # php php-only test (not run by the parsoid parser unless
27 # the test includes an html/parsoid section)
28 # showtitle make the first line the title
29 # comment run through Linker::formatComment() instead of main parser
30 # local format section links in edit comment text as local links
31 # notoc disable table of contents
32 # thumbsize=NNN set the default thumb size to NNNpx for this test
34 # You can also set the following parser properties via test options:
35 # wgEnableUploads, wgAllowExternalImages, wgMaxTocLevel,
36 # wgLinkHolderBatchSize, wgRawHtml
38 # For testing purposes, temporary articles can created:
39 # !!article / NAMESPACE:TITLE / !!text / ARTICLE TEXT / !!endarticle
40 # where '/' denotes a newline.
42 # This is the standard article assumed to exist.
67 MediaWiki:bad image list
69 * [[File:Bad.jpg]] except [[Nasty page]]
103 Template:echo_with_span
109 Template:echo_with_div
121 Template:table_attribs
124 |</noinclude>style="color: red"| Foo
130 {{table_attribs}} || Bar || Baz
134 Template:image_attribs
137 [[File:foobar.jpg|</noinclude>right|Caption text<noinclude>]]</noinclude>
171 This is a simple paragraph.
173 <p>This is a simple paragraph.
178 Paragraphs with extra newline spacing
201 Paragraphs with newline spacing with comment lines in between
209 <!--foo--><!--More than 1 comment, still stripped-->
213 <!--foo--> <!----> <!-- bar -->
274 Paragraphs with newline spacing with non-empty white-space lines in between
301 Paragraphs with newline spacing with non-empty mixed comment and white-space lines in between
309 <!--foo--><!--More than 1 comment doesn't disable stripping of this line!-->
348 Extra newlines: More paragraphs with indented comment
363 Extra newlines followed by heading
378 <h1><span class="mw-headline" id="b">b</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: b">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
379 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
382 <h1><span class="mw-headline" id="b_2">b</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: b">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
387 Extra newlines between heading and content are swallowed
395 <h1><span class="mw-headline" id="b">b</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: b">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
396 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
403 http://fr.wikipedia.org/wiki/🍺
404 <!-- EasterEgg we love beer, better be able be able to link to it -->
406 <p><a rel="nofollow" class="external free" href="http://fr.wikipedia.org/wiki/🍺">http://fr.wikipedia.org/wiki/🍺</a>
417 <li> Item 2</li></ul>
425 * plain''italic''plain
426 * plain''italic''plain''italic''plain
427 * plain'''bold'''plain
428 * plain'''bold'''plain'''bold'''plain
429 * plain''italic''plain'''bold'''plain
430 * plain'''bold'''plain''italic''plain
431 * plain''italic'''bold-italic'''italic''plain
432 * plain'''bold''bold-italic''bold'''plain
433 * plain'''''bold-italic'''italic''plain
434 * plain'''''bold-italic''bold'''plain
435 * plain''italic'''bold-italic'''''plain
436 * plain'''bold''bold-italic'''''plain
437 * plain l'''italic''plain
438 * plain l''''bold''' plain
441 <li> plain<i>italic</i>plain</li>
442 <li> plain<i>italic</i>plain<i>italic</i>plain</li>
443 <li> plain<b>bold</b>plain</li>
444 <li> plain<b>bold</b>plain<b>bold</b>plain</li>
445 <li> plain<i>italic</i>plain<b>bold</b>plain</li>
446 <li> plain<b>bold</b>plain<i>italic</i>plain</li>
447 <li> plain<i>italic<b>bold-italic</b>italic</i>plain</li>
448 <li> plain<b>bold<i>bold-italic</i>bold</b>plain</li>
449 <li> plain<i><b>bold-italic</b>italic</i>plain</li>
450 <li> plain<b><i>bold-italic</i>bold</b>plain</li>
451 <li> plain<i>italic<b>bold-italic</b></i>plain</li>
452 <li> plain<b>bold<i>bold-italic</i></b>plain</li>
453 <li> plain l'<i>italic</i>plain</li>
454 <li> plain l'<b>bold</b> plain</li></ul>
458 # this example taken from the [[simple:Moon]] article (bug 47326)
460 Italics and possessives (1)
462 obtained by ''[[Lunar Prospector]]'''s gamma-ray spectrometer
464 <p>obtained by <i><a href="/index.php?title=Lunar_Prospector&action=edit&redlink=1" class="new" title="Lunar Prospector (page does not exist)">Lunar Prospector</a>'</i>s gamma-ray spectrometer
468 # this example taken from [[en:Flaming Pie]] (bug 49926)
470 Italics and possessives (2)
472 '''''Flaming Pie''''' is ... released in 1997. In ''Flaming Pie'''s liner notes
474 <p><i><b>Flaming Pie</b></i> is ... released in 1997. In <i>Flaming Pie'</i>s liner notes
478 # this example taken from [[en:Dictionary]] (bug 49926)
480 Italics and possessives (3)
482 The first monolingual dictionary written in a Romance language was ''Sebastián Covarrubias''' ''Tesoro de la lengua castellana o española'', published in 1611 in Madrid. In 1612 the first edition of the ''Vocabolario dell'[[Accademia della Crusca]]'', for Italian, was published. In 1690 in Rotterdam was published, posthumously, the ''Dictionnaire Universel''.
484 <p>The first monolingual dictionary written in a Romance language was <i>Sebastián Covarrubias'</i> <i>Tesoro de la lengua castellana o española</i>, published in 1611 in Madrid. In 1612 the first edition of the <i>Vocabolario dell'<a href="/index.php?title=Accademia_della_Crusca&action=edit&redlink=1" class="new" title="Accademia della Crusca (page does not exist)">Accademia della Crusca</a></i>, for Italian, was published. In 1690 in Rotterdam was published, posthumously, the <i>Dictionnaire Universel</i>.
490 ### 2-quote opening sequence tests
493 Italics and bold: 2-quote opening sequence: (2,2)
503 Italics and bold: 2-quote opening sequence: (2,3)
514 # same html as previous, but wikitext adjusted to match parsoid html2wt
516 Italics and bold: 2-quote opening sequence: (2,3) w/ nowiki
518 ''<nowiki>foo'</nowiki>''
526 Italics and bold: 2-quote opening sequence: (2,4)
537 # same html as previous, but wikitext adjusted to match parsoid html2wt
539 Italics and bold: 2-quote opening sequence: (2,4) w/ nowiki
541 ''<nowiki>foo''</nowiki>''
548 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
550 Italics and bold: 2-quote opening sequence: (2,5)
563 # same html as previous, but wikitext adjusted to match parsoid html2wt
565 Italics and bold: 2-quote opening sequence: (2,5+3) w/ nowiki
567 ''foo'''''<nowiki/>'''
578 ### 3-quote opening sequence tests
582 Italics and bold: 3-quote opening sequence: (3,2)
592 Italics and bold: 3-quote opening sequence: (3,3)
602 Italics and bold: 3-quote opening sequence: (3,4)
613 # same html as previous, but wikitext adjusted to match parsoid html2wt
615 Italics and bold: 3-quote opening sequence: (3,4) w/ nowiki
617 '''<nowiki>foo'</nowiki>'''
624 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
626 Italics and bold: 3-quote opening sequence: (3,5)
639 # same html as previous, but wikitext adjusted to match parsoid html2wt
641 Italics and bold: 3-quote opening sequence: (3,5+2) w/ nowiki
643 '''foo'''''<nowiki/>''
654 ### 4-quote opening sequence tests
658 Italics and bold: 4-quote opening sequence: (4,2)
669 # same html as previous, but wikitext adjusted to match parsoid html2wt
671 Italics and bold: 4-quote opening sequence: (4,2) w/ nowiki
673 <nowiki>''</nowiki>''foo''
681 Italics and bold: 4-quote opening sequence: (4,3)
691 Italics and bold: 4-quote opening sequence: (4,4)
702 # same html as previous, but wikitext adjusted to match parsoid html2wt
704 Italics and bold: 4-quote opening sequence: (4,4) w/ nowiki
706 ''''<nowiki>foo'</nowiki>'''
713 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
715 Italics and bold: 4-quote opening sequence: (4,5)
724 <p>'<b>foo</b><i></i>
728 # same html as previous, but wikitext adjusted to match parsoid html2wt
730 Italics and bold: 4-quote opening sequence: (4,5+2) w/ nowiki
732 ''''foo'''''<nowiki/>''
737 <p>'<b>foo</b><i></i>
743 ### 5-quote opening sequence tests
747 Italics and bold: 5-quote opening sequence: (5,2)
758 # same html as previous, but wikitext adjusted to match parsoid html2wt
759 # skipping wt2html and html2html because it wants to put <i> before <b>
761 Italics and bold: 5-quote opening sequence: (5,2+3)
763 parsoid=wt2wt,html2wt
772 Italics and bold: 5-quote opening sequence: (5,3)
783 # same html as previous, but wikitext adjusted to match parsoid html2wt
785 Italics and bold: 5-quote opening sequence: (5,3+2)
795 Italics and bold: 5-quote opening sequence: (5,4)
801 <p><i><b>foo'</b></i>
806 # same html as previous, but wikitext adjusted to match parsoid html2wt
808 Italics and bold: 5-quote opening sequence: (5,4+2) w/ nowiki
810 '''''<nowiki>foo'</nowiki>'''''
812 <p><i><b>foo'</b></i>
818 Italics and bold: 5-quote opening sequence: (5,5)
827 ### multiple quote sequences in a line
830 Italics and bold: multiple quote sequences: (2,4,2)
836 <p><i>foo'<b>bar</b></i>
841 # same html as previous, but wikitext adjusted to match parsoid html2wt
843 Italics and bold: multiple quote sequences: (2,4,2+3) w/ nowiki
845 ''<nowiki>foo'</nowiki>'''bar'''''
847 <p><i>foo'<b>bar</b></i>
853 Italics and bold: multiple quote sequences: (2,4,3)
859 <p><i>foo'<b>bar</b></i>
864 # same html as previous, but wikitext adjusted to match parsoid html2wt
866 Italics and bold: multiple quote sequences: (2,4,3+2) w/ nowiki
868 ''<nowiki>foo'</nowiki>'''bar'''''
870 <p><i>foo'<b>bar</b></i>
876 Italics and bold: multiple quote sequences: (2,4,4)
882 <p><i>foo'<b>bar'</b></i>
887 # same html as previous, but wikitext adjusted to match parsoid html2wt
889 Italics and bold: multiple quote sequences: (2,4,4+2) w/ nowiki
891 ''<nowiki>foo'</nowiki>'''<nowiki>bar'</nowiki>'''''
893 <p><i>foo'<b>bar'</b></i>
898 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
900 Italics and bold: multiple quote sequences: (3,4,2)
909 <p><b>foo'</b>bar<i></i>
913 # same html as previous, but wikitext adjusted to match parsoid html2wt
915 Italics and bold: multiple quote sequences: (3,4,2+2) w/ nowiki
919 '''<nowiki>foo'</nowiki>'''bar''<nowiki/>''
924 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<i></i>
929 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
931 Italics and bold: multiple quote sequences: (3,4,3)
940 <p><b>foo'</b>bar<b></b>
944 # same html as previous, but wikitext adjusted to match parsoid html2wt
946 Italics and bold: multiple quote sequences: (3,4,3+3) w/ nowiki
948 '''<nowiki>foo'</nowiki>'''bar'''<nowiki/>'''
953 <p><b><span typeof="mw:Nowiki">foo'</span></b>bar<b></b>
958 ### other quote tests
961 Italics and bold: other quote tests: (2,3,5)
963 ''this is about '''foo's family'''''
965 <p><i>this is about <b>foo's family</b></i>
971 Italics and bold: other quote tests: (2,(3,3),2)
973 ''this is about '''foo's''' family''
975 <p><i>this is about <b>foo's</b> family</i>
981 Italics and bold: other quote tests: (3,2,3,2)
985 '''this is about ''foo'''s family''
987 <p><b>this is about <i>foo</i></b><i>s family</i>
992 # same html as previous, but wikitext adjusted to match parsoid html2wt
993 # add 'parsoid' option to use 'parsoid' normalization of the placeholder
995 Italics and bold: other quote tests: (3,2,3+2+2,2)
999 '''this is about ''foo'''''<nowiki/>''s family''
1001 <p><b>this is about <i>foo</i></b><i>s family</i>
1007 Italics and bold: other quote tests: (3,2,3,3)
1010 '''this is about ''foo'''s family'''
1012 <p>'<i>this is about </i>foo<b>s family</b>
1018 Italics and bold: other quote tests: (3,(2,2),3)
1020 '''this is about ''foo's'' family'''
1022 <p><b>this is about <i>foo's</i> family</b>
1028 Italicized possessive
1030 The ''[[Main Page]]'''s talk page.
1032 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
1037 Parsoid only: Quote balancing context should be restricted to td/th cells on the same wikitext line
1038 (Requires tidy for PHP parser output to be fixed up)
1040 parsoid=wt2html,wt2wt
1048 <tbody><tr><th><i>a</i></th><th><i>b</i></th>
1049 <td><i>a</i></td><td><i>b</i></td></tr>
1058 Non-html5 tags should be accepted
1060 <center>''foo''</center>
1062 <font>''foo''</font>
1063 <strike>''foo''</strike>
1066 <center><i>foo</i></center>
1067 <p><big><i>foo</i></big>
1068 <font><i>foo</i></font>
1069 <strike><i>foo</i></strike>
1075 <wbr> is valid wikitext (bug 52468)
1083 # <strike> is HTML4, <s> is HTML4/5.
1085 <s> or <strike> for strikethrough
1087 <strike>strike</strike>
1091 <p><strike>strike</strike>
1097 Non-word characters don't terminate tag names (bug 17663, 40670, 52022)
1099 <b→> doesn't work! </b→>
1101 <bä> doesn't work! </bä>
1103 <boo> works fine </boo>
1105 <s.foo>s.foo</s.foo>
1109 <p><b→> doesn't work! </b→>
1110 </p><p><bä> doesn't work! </bä>
1111 </p><p><boo> works fine </boo>
1112 </p><p><s.foo>s.foo</s.foo>
1113 </p><p><sub-ID#1>
1118 Isolated close tags should be treated as literal text (bug 52760)
1125 </p><p><s.foo>s</s>
1130 ### Special characters
1134 Bare pipe character (bug 52363)
1143 Bare pipe character from a template (bug 52363)
1152 ### <nowiki> test cases
1156 <nowiki> unordered list
1158 <nowiki>* This is not an unordered list item.</nowiki>
1160 <p>* This is not an unordered list item.
1167 <nowiki>Lorem ipsum dolor
1175 <p>Lorem ipsum dolor
1188 :There is not nowiki.
1189 :There is <nowiki>nowiki</nowiki>.
1191 #There is not nowiki.
1192 #There is <nowiki>nowiki</nowiki>.
1194 *There is not nowiki.
1195 *There is <nowiki>nowiki</nowiki>.
1197 <dl><dd>There is not nowiki.</dd>
1198 <dd>There is nowiki.</dd></dl>
1199 <ol><li>There is not nowiki.</li>
1200 <li>There is nowiki.</li></ol>
1201 <ul><li>There is not nowiki.</li>
1202 <li>There is nowiki.</li></ul>
1207 Entities inside <nowiki>
1209 <nowiki><</nowiki>
1216 Entities inside template parameters
1222 <p><span typeof="mw:Transclusion mw:Entity" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&ndash;"}},"i":0}}]}'>–</span>
1230 Comments and Indent-Pre
1232 <!-- comment 1 --> asdf
1234 <!-- comment 1 --> asdf
1237 <!-- comment 1 --> asdf
1238 <!-- comment 2 -->xyz
1240 <!-- comment 1 --> asdf
1241 <!-- comment 2 --> xyz
1297 asdf<!-- comment 1 -->jkl
1307 <!-- foo --> b <!-- bar -->
1321 <!-- returns a single newline, not nothing, since the newline after > is not stripped -->
1327 Comment semantics and delimiters
1329 <!-- --><!----><!-----><!------>
1335 Comment semantics and delimiters, redux
1337 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
1338 -- foo -- funky huh? ... -->
1344 Comment semantics and delimiters: directors cut
1346 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
1347 everything starting with < followed by !-- until the first -- and > we see,
1348 that wouldn't be valid XML however, since in XML -- has to terminate a comment
1356 Comment semantics: nesting
1358 <!--<!-- no, we're not going to do anything fancy here -->-->
1365 Comment semantics: unclosed comment at end
1367 <!--This comment will run out to the end of the document
1373 Comment in template title
1382 Comment on its own line post-expand
1394 Comment on its own line post-expand with non-significant whitespace
1406 Multiple comments should still parse as SOL-transparent
1408 parsoid=wt2html,wt2wt
1411 <!--c2--><!--c3--><!--c4-->*b
1422 ### paragraph wrapping tests
1437 Block tag on one line (<div>)
1449 Block tag on one line (<blockquote>)
1451 a <blockquote>foo</blockquote>
1455 a <blockquote>foo</blockquote>
1461 Block tag on both lines (<div>)
1473 Block tag on both lines (<blockquote>)
1475 a <blockquote>foo</blockquote>
1477 b <blockquote>foo</blockquote>
1479 a <blockquote>foo</blockquote>
1480 b <blockquote>foo</blockquote>
1485 Multiple lines without block tags
1503 Empty lines between lines with block tags
1532 ## PHP parser emits output which is broken
1534 Unclosed HTML p-tags should be handled properly
1541 <div data-parsoid='{"stx":"html"}'><p data-parsoid='{"stx":"html", "autoInsertedEnd":true}'>foo</p></div>
1547 ### Preformatted text
1556 And a [[Main Page|link]]
1562 And a <a href="/wiki/Main_Page" title="Main Page">link</a>
1567 Tabs don't trigger preformatted text
1571 This is preformatted text.
1577 <pre>This is preformatted text.
1583 Ident preformatting with inline content
1594 <pre> with <nowiki> inside (compatibility with 1.6 and earlier)
1611 Regression with preformatted in <center>
1625 Bug 52763: Preformatted in <blockquote>
1631 indented cell (no pre-wrapping!)
1641 <p> indented cell (no pre-wrapping!)
1649 Bug 51086: Double newlines in blockquotes should be turned into paragraphs
1666 Bug 15491: <ins>/<del> in blockquote
1669 Foo <del>bar</del> <ins>baz</ins> quux
1673 <p>Foo <del>bar</del> <ins>baz</ins> quux
1679 # Note that the p-wrapping is newline sensitive, which could be
1680 # considered a bug: tidy will wrap only the 'Foo' in the example
1681 # below in a <p> tag. (see comment 23-25 of bug #6200)
1683 Bug 15491: <ins>/<del> in blockquote (2)
1685 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1688 <blockquote>Foo <del>bar</del> <ins>baz</ins> quux
1694 <pre> with attributes (bug 3202)
1696 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1698 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1703 <pre> with width attribute (bug 3202)
1705 <pre width="8">Narrow screen goodies</pre>
1707 <pre width="8">Narrow screen goodies</pre>
1712 <pre> with forbidden attribute (bug 3202)
1714 <pre width="8" onmouseover="alert(document.cookie)">Narrow screen goodies</pre>
1716 <pre width="8">Narrow screen goodies</pre>
1721 Entities inside <pre>
1730 <pre> with forbidden attribute values (bug 3202)
1732 <pre width="8" style="border-width: expression(alert(document.cookie))">Narrow screen goodies</pre>
1734 <pre width="8" style="/* insecure input */">Narrow screen goodies</pre>
1739 <nowiki> inside <pre> (bug 13238)
1747 <pre><nowiki><nowiki></nowiki>Foo<nowiki></nowiki></nowiki></pre>
1755 <pre><nowiki>Foo</nowiki></pre>
1760 <nowiki> and <pre> preference (first one wins)
1791 </pre> inside nowiki
1793 <nowiki></pre></nowiki>
1800 Empty pre; pre inside other HTML tags (bug 54946)
1819 HTML pre followed by indent-pre
1834 <p><pre>foo</pre></p>
1836 <p data-parsoid='{"stx":"html","autoInsertedEnd":true}'></p><pre data-parsoid='{"stx":"html"}'>foo</pre><p data-parsoid='{"autoInsertedStart":true,"stx":"html"}'></p>
1840 Templates: Indent-Pre: 1a. Templates that break a line should suppress <pre>
1848 Templates: Indent-Pre: 1b. Templates that break a line should suppress <pre>
1858 Templates: Indent-Pre: 1c: Wrapping should be based on expanded content
1870 Templates: Indent-Pre: 1d: Wrapping should be based on expanded content
1891 Templates: Indent-Pre: 1e. Wrapping should be based on expanded content
1895 {{echo| foo}}{{echo| bar}}
1900 {{echo|<!--cmt--> foo}}
1902 <!--cmt-->{{echo| foo}}
1904 {{echo|{{echo| }}bar}}
1922 Templates: Indent-Pre: 1f: Wrapping should be based on expanded content
1959 Things that look like <pre> tags aren't treated as such
1961 Barack Obama <President> of the United States
1963 <p>Barack Obama <President> of the United States
1968 Parsoid: handle pre with space after attribute
1972 <pre style="width:50%;" >{{echo|foo}}</pre>
1974 <pre style="width:50%;">{{echo|foo}}</pre>
1977 # TODO / maybe: fix wt2wt for this
1979 Parsoid: Don't paragraph-wrap fosterable content
2005 Parsoid: Don't paragraph-wrap fosterable content even if table syntax is unbalanced
2033 #--------------------------------------------------------------------
2034 # Transclusion parameter whitespace stripping tests
2035 # Behavior is different for positional and named parameters
2036 #--------------------------------------------------------------------
2038 Templates: Strip leading and trailing whitespace from named-param values
2042 {{echo|1= {{echo|b}} }}
2055 <ul><li> d</li></ul>
2060 Templates: Don't strip whitespace from positional-param values
2064 {{echo|{{echo|b}} }}
2096 <ul><li> f</li></ul>
2104 Templates: Handle empty comment-and-ws-only lines correctly
2107 <!--should be ignored-->
2108 <!--should be ignored as well-->
2117 Templates: Handle comments in the target
2120 <!-- should be ignored -->
2123 {{echo<!-- should be ignored -->
2126 {{echo<!-- should be ignored -->|foo}}
2128 {{<!-- should be ignored -->echo|foo}}
2130 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo\n<!-- should be ignored -->\n","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2132 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo<!-- should be ignored -->\n","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2134 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo<!-- should be ignored -->","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2136 <p typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}}]}'>foo</p>
2139 #--------------------------------------------------------------------
2140 # Transclusion parameter escaping tests
2141 #--------------------------------------------------------------------
2143 Templates: Parsoid parameter escaping test 1
2147 {{echo|[foo]|{{echo|[bar]}}}}
2149 <p about="#mwt1" typeof="mw:Transclusion"
2150 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[foo]"},"2":{"wt":"{{echo|[bar]}}"}},"i":0}}]}'>[foo]</p>
2154 Parsoid: Pipes in external links in template parameter
2158 {{echo|[{{echo|http://example.com}} link]}}
2160 <p><a rel="mw:ExtLink" href="http://example.com" about="#mwt31" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[{{echo|http://example.com}} link]"}},"i":0}}]}'>link</a></p>
2164 Parsoid: pipe in transclusion parameter
2168 {{echo|http://foo.com/a|b}}
2170 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2171 typeof="mw:Transclusion"
2172 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"http://foo.com/a&#124;b"}},"i":0}}]}'>http://foo.com/a|b</a></p>
2176 Parsoid: Pipe in external link target and content in template parameter
2178 parsoid=html2wt,wt2wt
2180 {{echo|[http://foo.com/a|b a|b]}}
2182 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
2183 typeof="mw:Transclusion"
2184 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},
2185 "params":{"1":{"wt":"[http://foo.com/a|b a|b]"}},"i":0}}]}'>a|b</a></p>
2189 Templates: Don't escape already nowiki-escaped text in template parameters
2191 parsoid=html2wt,wt2wt
2193 {{echo|foo<nowiki>|</nowiki>bar}}
2194 {{echo|<nowiki><div></nowiki>}}
2195 {{echo|<nowiki></nowiki>}}
2197 <p><span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo<nowiki>|</nowiki>bar"}},"i":0}}]}'}'>foo</span><span typeof="mw:Nowiki" about="#mwt1">|</span><span about="#mwt1">bar</span>
2198 <span typeof="mw:Transclusion mw:Nowiki" about="#mwt2" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<nowiki>&lt;div&gt;</nowiki>"}},"i":0}}]}'><span typeof="mw:Entity"><</span>div<span typeof="mw:Entity">></span></span>
2199 <span typeof="mw:Transclusion mw:Nowiki" about="#mwt3" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<nowiki></nowiki>"}},"i":0}}]}'></span>
2205 Templates: '=' char in nested transclusions should not trigger nowiki escapes or conversion to named param
2207 parsoid=html2wt,wt2wt
2209 {{echo|{{echo|1=bar}}}}
2211 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"{{echo|1=bar}}"}},"i":0}}]}'>bar</p>
2216 Templates parameters with special tokenizing behavior dont get modified because of arg escaping
2222 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a : b"}},"i":0}}]}'>a<span typeof="mw:Placeholder" data-parsoid='{"isDisplayHack":true}'> </span>: b</p>
2226 ### Parsoid-centric tests for testing RT edge cases for pre
2230 1a. Indent-Pre and Comments
2243 1b. Indent-Pre and Comments
2256 1c. Indent-Pre and Comments
2269 1d. Indent-Pre and Comments
2270 (Pre-handler currently cannot distinguish between comment/ws order and normalizes them to [comment,ws] order)
2283 2a. Indent-Pre and tables
2304 2b. Indent-Pre and tables
2320 2c. Indent-Pre and tables (bug 42252)
2337 3a. Indent-Pre and block tags (single-line html)
2341 c <blockquote> foo </blockquote>
2346 c <blockquote> foo </blockquote>
2347 <pre><span> foo </span>
2352 3b. Indent-Pre and block tags (multi-line html)
2357 <pre>a <span>foo</span>
2364 3c. Indent-Pre and block tags (pre-content on separate line)
2428 4. Indent-Pre and extension tags
2434 a <ul class="gallery mw-gallery-traditional">
2435 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
2436 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
2437 <div class="gallerytext">
2445 Leading pipes outside of tables
2455 Leading pipes outside of tables 2
2469 Leading pipes outside of tables 3
2474 | class="foo bar" | baz
2478 | class="foo bar" | baz
2483 Render paragraphs when indent-pre is suppressed in blocklevels
2500 4. Multiple spaces at start-of-line
2518 ## NOTE: the leading white-space chars on empty line are significant
2520 5a. White-space in indent-pre
2532 ## NOTE: the leading white-space chars on empty line are significant
2534 5b. White-space in indent-pre
2553 5c. White-space in indent-pre
2566 6. Pre-blocks should extend across lines with leading WS even when there is no wrappable content
2589 7a. Indent-pre and category links
2591 parsoid=wt2html,wt2wt
2593 [[Category:foo]] <!-- No pre-wrapping -->
2594 {{echo| [[Category:foo]]}} <!-- No pre-wrapping -->
2596 <link rel="mw:PageProp/Category" href="./Category:Foo"> <!-- No pre-wrapping -->
2597 <span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":" [[Category:foo]]"}},"i":0}}]}'> </span>
2598 <link rel="mw:PageProp/Category" href="./Category:Foo" about="#mwt1"> <!-- No pre-wrapping -->
2602 7b. Indent-pre and category links
2604 parsoid=wt2html,wt2wt
2607 [[Category:foo]] {{echo|b}}
2610 <link rel="mw:PageProp/Category" href="./Category:Foo"> a
2612 <link rel="mw:PageProp/Category" href="./Category:Foo"> <span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b"}},"i":0}}]}'>b</span></pre>
2616 ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric)
2620 HTML-pre: 1. embedded newlines
2656 HTML-pre: 2: indented text
2669 HTML-pre: 3: other wikitext
2690 ### Definition lists
2697 <dl><dt> name </dt>
2698 <dd> Definition</dd></dl>
2703 Definition list for indentation only
2707 <dl><dd> Indented text</dd></dl>
2712 Definition list with no space
2717 <dd>Definition</dd></dl>
2722 Definition list with URL link
2724 ; http://example.com/ : definition
2726 <dl><dt> <a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> </dt>
2727 <dd> definition</dd></dl>
2732 Definition list with bracketed URL link
2734 ;[http://www.example.com/ Example]:Something about it
2736 <dl><dt><a rel="nofollow" class="external text" href="http://www.example.com/">Example</a></dt>
2737 <dd>Something about it</dd></dl>
2742 Definition list with wikilink containing colon
2744 ; [[Help:FAQ]]: The least-read page on Wikipedia
2746 <dl><dt> <a href="/index.php?title=Help:FAQ&action=edit&redlink=1" class="new" title="Help:FAQ (page does not exist)">Help:FAQ</a></dt>
2747 <dd> The least-read page on Wikipedia</dd></dl>
2751 # At Brion's and JeLuF's insistence... :)
2753 Definition list with news link containing colon
2755 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
2757 <dl><dt> <a rel="nofollow" class="external free" href="news:alt.wikipedia.rox">news:alt.wikipedia.rox</a></dt>
2758 <dd> This isn't even a real newsgroup!</dd></dl>
2763 Malformed definition list with colon
2765 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
2767 <dl><dt> <a rel="nofollow" class="external free" href="news:alt.wikipedia.rox">news:alt.wikipedia.rox</a> -- don't crash or enter an infinite loop</dt></dl>
2772 Definition lists: colon in external link text
2774 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
2776 <dl><dt> <a rel="nofollow" class="external text" href="http://www.wikipedia2.org/">Wikipedia : The Next Generation</a></dt>
2777 <dd> OK, I made that up</dd></dl>
2782 Definition lists: colon in HTML attribute
2784 ;<b style="display: inline">bold</b>
2786 <dl><dt><b style="display: inline">bold</b></dt></dl>
2791 Definition lists: self-closed tag
2793 ;one<br/>two : two-line fun
2795 <dl><dt>one<br />two </dt>
2796 <dd> two-line fun</dd></dl>
2801 Bug 11748: Literal closing tags
2805 <dd>test test test test test</dd>
2807 <dd>test test test test test</dd>
2812 <dd>test test test test test</dd>
2814 <dd>test test test test test</dd>
2820 Definition and unordered list using wiki syntax nested in unordered list using html tags.
2823 ; term : description
2828 <dl><dt> term </dt>
2829 <dd> description</dd></dl>
2830 <ul><li> unordered</li></ul>
2837 Definition list with empty definition and following paragraph
2849 Nested definition lists using html syntax
2858 Definition Lists: No nesting: Multiple dd's
2871 Definition Lists: Indentation: Regular
2879 <dl><dd>i3</dd></dl></dd></dl></dd></dl>
2884 Definition Lists: Indentation: Missing 1st level
2890 <dl><dd>i3</dd></dl></dd></dl></dd></dl>
2895 Definition Lists: Indentation: Multi-level indent
2899 <dl><dd><dl><dd><dl><dd>i3</dd></dl></dd></dl></dd></dl>
2904 Definition Lists: Hacky use to indent tables
2911 should be left alone
2913 <dl><dd><dl><dd><table>
2918 </td></tr></table></dd></dl></dd></dl>
2920 should be left alone
2925 Definition Lists: Hacky use to indent tables, with comments (bug 63979)
2933 should be left alone
2936 <dl><dd><dl><dd><table><tr>
2939 </tr></table><!-- bar --></dd></dl></dd></dl>
2941 should be left alone</p>
2945 Definition Lists: Hacky use to indent tables, with comment before table
2951 <dl><dd><dl><dd><!-- foo --><table><tr>
2953 </tr></table></dd></dl></dd></dl>
2958 Definition Lists: Hacky use to indent tables (WS-insensitive)
2967 <dd> <table><tr><td>a</td></tr></table> </dd>
2970 ## The PHP parser treats : items (dd) without a corresponding ; item (dt)
2971 ## as an empty dt item. It also ignores all but the last ";" when followed
2972 ## by ":" later on. So, ";" are not ignored in ";;;t3" but are ignored in
2973 ## ";;;t3 :d1". So, PHP parser behavior is a little inconsistent wrt multiple
2976 ## Ex: ";;t2 ::d2" is transformed into:
2988 ## But, Parsoid treats "; :" as a tight atomic unit and excess ":" as plain text
2989 ## So, the same wikitext above (;;t2 ::d2) is transformed into:
3000 ## All Parsoid only definition list tests have this difference.
3002 ## See also: https://bugzilla.wikimedia.org/show_bug.cgi?id=6569
3003 ## and http://lists.wikimedia.org/pipermail/wikitext-l/2011-November/000483.html
3006 Table / list interaction: indented table with lists in table contents
3021 <ul><li> b</li></ul>
3025 <ul><li> d</li></ul>
3026 </td></tr></table></dd></dl>
3031 Table / list interaction: lists nested in tables nested in indented lists
3054 </td></tr></table></dd></dl>
3061 Definition Lists: Nesting: Multi-level (Parsoid only)
3091 Definition Lists: Nesting: Test 2 (Parsoid only)
3111 Definition Lists: Nesting: Test 3 (Parsoid only)
3139 Definition Lists: Nesting: Test 4
3144 <dl><dd><dl><dd><dl><dt>t3</dt>
3145 <dd>d3</dd></dl></dd></dl></dd></dl>
3150 ## The Parsoid team believes the following three test exposes a
3151 ## bug in the PHP parser. (Parsoid team thinks the PHP parser is
3152 ## wrong to close the <dl> after the <dt> containing the <ul>.)
3154 Definition Lists: Mixed Lists: Test 1
3160 <dl><dd><dl><dt><ul><li> foo</li>
3161 <li> bar</li></ul></dt></dl>
3162 <dl><dt> baz</dt></dl></dd></dl>
3181 Definition Lists: Mixed Lists: Test 2
3186 <ul><li><dl><dd> d1</dd>
3187 <dd> d2</dd></dl></li></ul>
3193 Definition Lists: Mixed Lists: Test 3
3198 <ul><li><dl><dd><dl><dd><dl><dd> d1</dd>
3199 <dd> d2</dd></dl></dd></dl></dd></dl></li></ul>
3205 Definition Lists: Mixed Lists: Test 4
3210 <ul><li><dl><dt>d1 </dt>
3213 <dd>d4</dd></dl></li></ul>
3219 Definition Lists: Mixed Lists: Test 5
3225 <dl><dd> d2</dd></dl></dd></dl></li></ul>
3231 Definition Lists: Mixed Lists: Test 6
3236 <ol><li><ul><li><dl><dd>d1
3237 <dl><dd><dl><dd> d3</dd></dl></dd></dl></dd></dl></li></ul></li></ol>
3243 Definition Lists: Mixed Lists: Test 7
3248 <dl><dd><ul><li> d1</li>
3249 <li> d2</li></ul></dd></dl>
3255 Definition Lists: Mixed Lists: Test 8
3260 <dl><dd><ul><li> d1</li></ul>
3261 <dl><dd><ul><li> d2</li></ul></dd></dl></dd></dl>
3267 Definition Lists: Mixed Lists: Test 9
3271 <ul><li><dl><dt>foo </dt>
3272 <dd>bar</dd></dl></li></ul>
3278 Definition Lists: Mixed Lists: Test 10
3282 <ul><li><ol><li><dl><dt>foo </dt>
3283 <dd>bar</dd></dl></li></ol></li></ul>
3287 # The Parsoid team disagrees with the PHP parser's seemingly-random
3288 # rules regarding dd/dt on the next two tests. Parsoid is more
3289 # consistent, and recognizes the shared nesting and keeps the
3290 # still-open tags around until the nesting is complete.
3293 Definition Lists: Mixed Lists: Test 11
3298 <ul><li><ol><li><ul><li><ol><li><dl><dt>foo </dt>
3299 <dd><ul><li><dl><dt><dl><dt>bar</dt></dl></dd></dl></li></ul></dd></dl>
3300 <dl><dt>boo </dt>
3301 <dd>baz</dd></dl></li></ol></li></ul></li></ol></li></ul>
3319 <dt>foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3320 <dd data-parsoid='{"stx":"row"}'>bar</dd>
3324 <dt>boo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3325 <dd data-parsoid='{"stx":"row"}'>baz</dd>
3335 Definition Lists: Weird Ones: Test 1
3337 *#;*::;; foo : bar (who uses this?)
3339 <ul><li><ol><li><dl><dt> foo </dt>
3340 <dd><ul><li><dl><dd><dl><dd><dl><dt><dl><dt> bar (who uses this?)</dt></dl></dd></dl></dd></dl></dd></dl></li></ul></dd></dl></li></ol></li></ul>
3358 <dt> foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
3359 <dd data-parsoid='{"stx":"row"}'> bar (who uses this?)</dd>
3374 External links: non-bracketed
3376 Non-bracketed: http://example.com
3378 <p>Non-bracketed: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
3382 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
3384 External links: numbered
3386 Numbered: [http://example.com]
3387 Numbered: [http://example.net]
3388 Numbered: [http://example.com]
3390 <p>Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[1]</a>
3391 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.net">[2]</a>
3392 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[3]</a>
3395 <p>Numbered: <a rel="mw:ExtLink" href="http://example.com"></a>
3396 Numbered: <a rel="mw:ExtLink" href="http://example.net"></a>
3397 Numbered: <a rel="mw:ExtLink" href="http://example.com"></a></p>
3401 External links: specified text
3403 Specified text: [http://example.com link]
3405 <p>Specified text: <a rel="nofollow" class="external text" href="http://example.com">link</a>
3410 External links: trail
3412 Linktrails should not work for external links: [http://example.com link]s
3414 <p>Linktrails should not work for external links: <a rel="nofollow" class="external text" href="http://example.com">link</a>s
3419 External links: dollar sign in URL
3421 http://example.com/1$2345
3423 <p><a rel="nofollow" class="external free" href="http://example.com/1$2345">http://example.com/1$2345</a>
3427 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
3429 External links: dollar sign in URL (autonumber)
3431 [http://example.com/1$2345]
3433 <p><a rel="nofollow" class="external autonumber" href="http://example.com/1$2345">[1]</a>
3436 <p><a rel="mw:ExtLink" href="http://example.com/1$2345"></a></p>
3440 External links: open square bracket forbidden in URL (bug 4377)
3442 parsoid=wt2html,wt2wt,html2html
3444 http://example.com/1[2345
3446 <p><a rel="nofollow" class="external free" href="http://example.com/1">http://example.com/1</a>[2345
3449 <p><a rel="mw:ExtLink" href="http://example.com/1">http://example.com/1</a>[2345</p>
3453 External links: open square bracket forbidden in URL (named) (bug 4377)
3455 parsoid=wt2html,html2html
3457 [http://example.com/1[2345]
3459 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
3462 <p><a rel="mw:ExtLink" href="http://example.com/1">[2345</a></p>
3465 # parsoid adds a space before the link name
3467 External links: open square bracket forbidden in URL (named) (bug 4377)
3470 [http://example.com/1 [2345]
3472 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
3477 External links: nowiki in URL link text (bug 6230)
3479 [http://example.com/ <nowiki>''example site''</nowiki>]
3481 <p><a rel="nofollow" class="external text" href="http://example.com/">''example site''</a>
3486 External links: newline forbidden in text (bug 6230 regression check)
3488 [http://example.com/ first
3491 <p>[<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> first
3497 External links: Pipe char between url and text
3499 [http://example.com | link]
3501 <p><a rel="nofollow" class="external text" href="http://example.com">| link</a>
3506 External links: protocol-relative URL in brackets
3508 [//example.com/ Test]
3510 <p><a rel="nofollow" class="external text" href="//example.com/">Test</a>
3514 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
3516 External links: protocol-relative URL in brackets without text
3520 <p><a rel="nofollow" class="external autonumber" href="//example.com">[1]</a>
3523 <p><a rel="mw:ExtLink" href="//example.com"></a></p>
3527 External links: protocol-relative URL in free text is left alone
3531 <p>//example.com/Foo
3536 External links: protocol-relative URL in the middle of a word is left alone (bug 30269)
3538 foo//example.com/Foo
3540 <p>foo//example.com/Foo
3547 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
3549 <p>External image: <img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
3554 External image from https
3556 External image from https: https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
3558 <p>External image from https: <img src="https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
3563 External image (when not allowed)
3565 wgAllowExternalImages=0
3567 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
3569 <p>External image: <a rel="nofollow" class="external free" href="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png">http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png</a>
3574 Link to non-http image, no img tag
3576 Link to non-http image, no img tag: ftp://example.com/test.jpg
3578 <p>Link to non-http image, no img tag: <a rel="nofollow" class="external free" href="ftp://example.com/test.jpg">ftp://example.com/test.jpg</a>
3583 External links: terminating separator
3585 Terminating separator: http://example.com/thing,
3587 <p>Terminating separator: <a rel="nofollow" class="external free" href="http://example.com/thing">http://example.com/thing</a>,
3592 External links: intervening separator
3594 Intervening separator: http://example.com/1,2,3
3596 <p>Intervening separator: <a rel="nofollow" class="external free" href="http://example.com/1,2,3">http://example.com/1,2,3</a>
3601 External links: old bug with URL in query
3603 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
3605 <p>Old bug with URL in query: <a rel="nofollow" class="external text" href="http://example.com/thing?url=http://example.com">link</a>
3610 External links: old URL-in-URL bug, mixed protocols
3612 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
3614 <p>And again with mixed protocols: <a rel="nofollow" class="external text" href="ftp://example.com?url=http://example.com">link</a>
3619 External links: URL in text
3621 URL in text: [http://example.com http://example.com]
3623 <p>URL in text: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
3628 External links: Clickable images
3630 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
3632 <p>ja-style clickable images: <a rel="nofollow" class="external text" href="http://example.com"><img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" /></a>
3637 External links: raw ampersand
3639 Old & use: http://x&y
3641 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
3646 External links: encoded ampersand
3648 Old & use: http://x&y
3650 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
3653 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y">http://x&y</a></p>
3657 External links: encoded equals (bug 6102)
3659 http://example.com/?foo=bar
3661 <p><a rel="nofollow" class="external free" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a>
3664 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a></p>
3668 ## Note that parsoid doesn't explicit mark autonumbered links, nor
3669 ## does it number them. As discussed in bug 53505, we can identify
3670 ## autonumbered links via CSS.
3674 External links: [raw ampersand]
3676 Old & use: [http://x&y]
3678 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3681 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y"></a></p>
3684 # note that parsoid html is identical to [raw ampersand] case; so html2wt
3685 # mode will return the [raw ampersand] wikitext
3687 External links: [encoded ampersand]
3689 parsoid=wt2html,wt2wt,html2html
3691 Old & use: [http://x&y]
3693 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3696 <p>Old <span typeof="mw:Entity">&</span> use: <a rel="mw:ExtLink" href="http://x&y"></a></p>
3700 External links: [raw equals]
3702 [http://example.com/?foo=bar]
3704 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
3707 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar"></a></p>
3710 # note that parsoid html is identical to [raw equals] case; so html2wt
3711 # mode will return the [raw equals] wikitext
3713 External links: [encoded equals] (bug 6102)
3715 parsoid=wt2html,wt2wt,html2html
3717 [http://example.com/?foo=bar]
3719 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
3722 <p><a rel="mw:ExtLink" href="http://example.com/?foo=bar"></a></p>
3725 # xxx parsoid strips the IDN character, so the round-trip tests will
3726 # obviously fail and are disabled. --cscott
3728 External links: [IDN ignored character reference in hostname; strip it right off]
3730 parsoid=wt2html,wt2wt,html2html
3732 [http://e‌xample.com/]
3734 <p><a rel="nofollow" class="external autonumber" href="http://example.com/">[1]</a>
3737 <p><a rel="mw:ExtLink" href="http://example.com/"></a></p>
3740 # FIXME: This test (the IDN characters in the text of a link) is an inconsistency.
3741 # Where an external link could easily circumvent the sanitization of the text of
3742 # a link like this (where an IDN-ignore character is in the URL somewhere), this
3743 # test demands a higher standard. That's a bit strange.
3747 # http://example.com -> [http://example.com|http://example.com]
3748 # [http://example.com|http://example.com] -> [http://example.com|http://example.com]
3750 # The first example is sanitized, but the second is not. Any security benefits
3751 # from this production are trivial to circumvent. Either remove this test and
3752 # let the parser(s) do their thing unaccosted, or fix the inconsistency and change
3753 # the test accordingly.
3757 # xxx parsoid strips the IDN character, so the round-trip tests will
3758 # obviously fail and are disabled. --cscott
3760 External links: IDN ignored character reference in hostname; strip it right off
3762 parsoid=wt2html,html2html
3764 http://e‌xample.com/
3766 <p><a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>
3769 <p><a rel="mw:ExtLink" href="http://example.com/">http://example.com/</a></p>
3773 External links: www.jpeg.org (bug 554)
3777 <p><a rel="nofollow" class="external free" href="http://www.jpeg.org">http://www.jpeg.org</a>
3781 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
3783 External links: URL within URL (original bug 2)
3785 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
3787 <p><a rel="nofollow" class="external autonumber" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp">[1]</a>
3790 <p><a rel="mw:ExtLink" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp"></a></p>
3794 BUG 361: URL inside bracketed URL
3796 [http://www.example.com/foo http://www.example.com/bar]
3798 <p><a rel="nofollow" class="external text" href="http://www.example.com/foo">http://www.example.com/bar</a>
3803 BUG 361: URL within URL, not bracketed
3805 http://www.example.com/foo?=http://www.example.com/bar
3807 <p><a rel="nofollow" class="external free" href="http://www.example.com/foo?=http://www.example.com/bar">http://www.example.com/foo?=http://www.example.com/bar</a>
3812 BUG 289: ">"-token in URL-tail
3814 http://www.example.com/<hello>
3816 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><hello>
3821 BUG 289: literal ">"-token in URL-tail
3823 http://www.example.com/<b>html</b>
3825 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><b>html</b>
3830 BUG 289: ">"-token in bracketed URL
3832 [http://www.example.com/<hello> stuff]
3834 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><hello> stuff</a>
3839 BUG 289: literal ">"-token in bracketed URL
3841 [http://www.example.com/<b>html</b> stuff]
3843 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><b>html</b> stuff</a>
3848 BUG 289: literal double quote at end of URL
3850 http://www.example.com/"hello"
3852 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a>"hello"
3857 BUG 289: literal double quote in bracketed URL
3859 [http://www.example.com/"hello" stuff]
3861 <p><a rel="nofollow" class="external text" href="http://www.example.com/">"hello" stuff</a>
3866 External links: multiple legal whitespace is fine, Magnus. Don't break it please. (bug 5081)
3868 [http://www.example.com test]
3870 <p><a rel="nofollow" class="external text" href="http://www.example.com">test</a>
3875 External links: link text with spaces
3877 [http://www.example.com a b c]
3878 [http://www.example.com ''a'' ''b'']
3880 <p><a rel="nofollow" class="external text" href="http://www.example.com">a b c</a>
3881 <a rel="nofollow" class="external text" href="http://www.example.com"><i>a</i> <i>b</i></a>
3886 External links: wiki links within external link (Bug 3695)
3888 [http://example.com [[wikilink]] embedded in ext link]
3890 <p><a rel="nofollow" class="external text" href="http://example.com"></a><a href="/index.php?title=Wikilink&action=edit&redlink=1" class="new" title="Wikilink (page does not exist)">wikilink</a><a rel="nofollow" class="external text" href="http://example.com"> embedded in ext link</a>
3893 <p><a rel="mw:ExtLink" href="http://example.com"></a><a rel="mw:WikiLink" href="./Wikilink">wikilink</a><span> embedded in ext link</span></p>
3897 BUG 787: Links with one slash after the url protocol are invalid
3901 [http:/example.com title]
3903 <p>http:/example.com
3904 </p><p>[http:/example.com title]
3909 Bracketed external links with template-generated invalid target
3911 [{{echo|http:/example.com}} title]
3913 <p>[http:/example.com title]
3918 Bug 2702: Mismatched <i>, <b> and <a> tags are invalid
3920 ''[http://example.com text'']
3921 [http://example.com '''text]'''
3922 ''Something [http://example.com in italic'']
3923 ''Something [http://example.com mixed''''', even bold]'''
3924 '''''Now [http://example.com both''''']
3926 <p><a rel="nofollow" class="external text" href="http://example.com"><i>text</i></a>
3927 <a rel="nofollow" class="external text" href="http://example.com"><b>text</b></a>
3928 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>in italic</i></a>
3929 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>mixed</i><b>, even bold</b></a>
3930 <i><b>Now </b></i><a rel="nofollow" class="external text" href="http://example.com"><i><b>both</b></i></a>
3936 Bug 4781: %26 in URL
3938 http://www.example.com/?title=AT%26T
3940 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a>
3943 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a></p>
3946 # According to http://dev.w3.org/html5/spec/Overview.html#parsing-urls a plain
3947 # % is actually legal in HTML5. Any change in output would need testing though.
3949 Bug 4781, 5267: %25 in URL
3951 http://www.example.com/?title=100%25_Bran
3953 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=100%25_Bran">http://www.example.com/?title=100%25_Bran</a>
3956 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=100%25_Bran">http://www.example.com/?title=100%25_Bran</a></p>
3960 Bug 4781, 5267: %28, %29 in URL
3962 http://www.example.com/?title=Ben-Hur_%281959_film%29
3964 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">http://www.example.com/?title=Ben-Hur_%281959_film%29</a>
3967 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">http://www.example.com/?title=Ben-Hur_%281959_film%29</a></p>
3972 Bug 4781: %26 in autonumber URL
3974 [http://www.example.com/?title=AT%26T]
3976 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=AT%26T">[1]</a>
3979 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T"></a></p>
3983 Bug 4781, 5267: %26 in autonumber URL
3985 [http://www.example.com/?title=100%25_Bran]
3987 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=100%25_Bran">[1]</a>
3990 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=100%25_Bran"></a></p>
3994 Bug 4781, 5267: %28, %29 in autonumber URL
3996 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
3998 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">[1]</a>
4001 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29"></a></p>
4006 Bug 4781: %26 in bracketed URL
4008 [http://www.example.com/?title=AT%26T link]
4010 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=AT%26T">link</a>
4013 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=AT%26T">link</a></p>
4017 Bug 4781, 5267: %25 in bracketed URL
4019 [http://www.example.com/?title=100%25_Bran link]
4021 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=100%25_Bran">link</a>
4026 Bug 4781, 5267: %28, %29 in bracketed URL
4028 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
4030 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a>
4033 <p><a rel="mw:ExtLink" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a></p>
4036 # Note that parsoid does not munge anchor text; all non-space
4037 # characters are valid in HTML5 ids.
4039 Anchor containing a #. (bug 63430)
4041 [[Main Page#And#Link]]
4043 <p><a href="/wiki/Main_Page#And.23Link" title="Main Page">Main Page#And#Link</a>
4046 <p><a rel="mw:WikiLink" href="./Main_Page#And%23Link">Main Page#And#Link</a></p>
4050 External link containing a period in the anchor. (bug 63947)
4052 [//foo.org/bar#baz. bang]
4054 [//foo.org/bar. bang]
4056 <p><a rel="nofollow" class="external text" href="//foo.org/bar#baz.">bang</a>
4057 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar.">bang</a>
4060 <p><a rel="mw:ExtLink" href="//foo.org/bar#baz.">bang</a></p>
4061 <p><a rel="mw:ExtLink" href="//foo.org/bar.">bang</a></p>
4065 External link containing a single quote. (bug 63947)
4069 [//foo.org/bar'baz bang]
4071 <p><a rel="nofollow" class="external autonumber" href="//foo.org/bar'baz">[1]</a>
4072 </p><p><a rel="nofollow" class="external text" href="//foo.org/bar'baz">bang</a>
4075 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz"></a></p>
4076 <p><a rel="mw:ExtLink" href="//foo.org/bar'baz">bang</a></p>
4081 External link containing double-single-quotes in text '' (bug 4598 sanity check)
4083 Some [http://example.com/ pretty ''italics'' and stuff]!
4085 <p>Some <a rel="nofollow" class="external text" href="http://example.com/">pretty <i>italics</i> and stuff</a>!
4090 External link containing double-single-quotes in text embedded in italics (bug 4598 sanity check)
4092 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
4094 <p><i>Some </i><a rel="nofollow" class="external text" href="http://example.com/"><i>pretty </i>italics<i> and stuff</i></a><i>!</i>
4099 External link containing double-single-quotes with no space separating the url from text in italics
4101 [http://www.musee-picasso.fr/pages/page_id18528_u1l2.htm''La muerte de Casagemas'' (1901) en el sitio de [[Museo Picasso (París)|Museo Picasso]].]
4103 <p><a rel="nofollow" class="external text" href="http://www.musee-picasso.fr/pages/page_id18528_u1l2.htm"><i>La muerte de Casagemas</i> (1901) en el sitio de <a href="/index.php?title=Museo_Picasso_(Par%C3%ADs)&action=edit&redlink=1" class="new" title="Museo Picasso (París) (page does not exist)">Museo Picasso</a>.</a>
4106 <p><a rel="mw:ExtLink" href="http://www.musee-picasso.fr/pages/page_id18528_u1l2.htm"><i>La muerte de Casagemas</i> (1901) en el sitio de </a><a rel="mw:WikiLink" href="./Museo_Picasso_(París)">Museo Picasso</a><span>.</span></p>
4110 External link with comments in link text
4112 [http://www.google.com Google <!-- comment -->]
4114 <p><a rel="nofollow" class="external text" href="http://www.google.com">Google </a>
4119 URL-encoding in URL functions (single parameter)
4121 {{localurl:Some page|amp=&}}
4123 <p>/index.php?title=Some_page&amp=&
4128 URL-encoding in URL functions (multiple parameters)
4130 {{localurl:Some page|q=?&=&}}
4132 <p>/index.php?title=Some_page&q=?&amp=&
4139 http://example.com/index.php?foozoid%5B%5D=bar
4141 http://example.com/index.php?foozoid[]=bar
4143 <p><a rel="nofollow" class="external free" href="http://example.com/index.php?foozoid%5B%5D=bar">http://example.com/index.php?foozoid%5B%5D=bar</a>
4144 </p><p><a rel="nofollow" class="external free" href="http://example.com/index.php?foozoid%5B%5D=bar">http://example.com/index.php?foozoid%5B%5D=bar</a>
4147 <p><a rel="mw:ExtLink" href="http://example.com/index.php?foozoid%5B%5D=bar">http://example.com/index.php?foozoid%5B%5D=bar</a></p>
4149 <p><a rel="mw:ExtLink" href="http://example.com/index.php?foozoid[]=bar">http://example.com/index.php?foozoid[]=bar</a></p>
4153 IPv6 urls (bug 21261)
4157 http://[2404:130:0:1000::187:2]/index.php
4159 <p><a rel="nofollow" class="external free" href="http://[2404:130:0:1000::187:2]/index.php">http://[2404:130:0:1000::187:2]/index.php</a>
4164 Non-extlinks in brackets
4173 [{{echo|foo}} ''bar'']
4174 [{{echo|foo}}l's] errand
4175 [{{echo|foo}}l's errand]
4177 [url=http://example.com]
4190 [url=<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>]
4195 Percent encoding in external links
4197 [https://github.com/search?l=&q=ResourceLoader+%40wikimedia Search]
4199 <p><a rel="nofollow" class="external text" href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a>
4202 <p><a rel="mw:ExtLink"
4203 href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a></p>
4207 Use url link syntax for links where the content is equal the link target
4211 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
4214 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></p>
4218 Parenthesis in external links, especially URL links
4222 http://example.com/test)
4224 http://example.com/(test)
4226 http://example.com/((test)
4228 (http://example.com/(test))
4230 (http://example.com/(test)))))
4232 http://example.com/a)b
4234 [http://example.com) foo]
4236 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4237 </p><p><a rel="nofollow" class="external free" href="http://example.com/test">http://example.com/test</a>)
4238 </p><p><a rel="nofollow" class="external free" href="http://example.com/(test)">http://example.com/(test)</a>
4239 </p><p><a rel="nofollow" class="external free" href="http://example.com/((test)">http://example.com/((test)</a>
4240 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test))">http://example.com/(test))</a>
4241 </p><p>(<a rel="nofollow" class="external free" href="http://example.com/(test)))))">http://example.com/(test)))))</a>
4242 </p><p><a rel="nofollow" class="external free" href="http://example.com/a)b">http://example.com/a)b</a>
4243 </p><p><a rel="nofollow" class="external text" href="http://example.com)">foo</a>
4246 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a>)</p>
4247 <p><a rel="mw:ExtLink" href="http://example.com/test">http://example.com/test</a>)</p>
4248 <p><a rel="mw:ExtLink" href="http://example.com/(test)">http://example.com/(test)</a></p>
4249 <p><a rel="mw:ExtLink" href="http://example.com/((test)">http://example.com/((test)</a></p>
4250 <p>(<a rel="mw:ExtLink" href="http://example.com/(test))">http://example.com/(test))</a></p>
4251 <p>(<a rel="mw:ExtLink" href="http://example.com/(test)))))">http://example.com/(test)))))</a></p>
4252 <p><a rel="mw:ExtLink" href="http://example.com/a)b">http://example.com/a)b</a></p>
4253 <p><a rel="mw:ExtLink" href="http://example.com)">foo</a></p>
4257 Parenthesis in external links, w/ transclusion or comment
4259 (http://example.com/{{echo|hi}})
4261 (http://example.com<!-- hi -->)
4263 <p>(<a rel="nofollow" class="external free" href="http://example.com/hi">http://example.com/hi</a>)
4264 </p><p>(<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>)
4267 <p>(<a data-mw='{"attribs":[[{"txt":"href"},{"html":"http://example.com/<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;hi&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;dsr&quot;:[20,31,null,null],&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]]}\">hi</span>"}]]}' typeof="mw:ExpandedAttrs" about="#mwt2" rel="mw:ExtLink" href="http://example.com/hi" data-parsoid='{"stx":"url","a":{"href":"http://example.com/hi"},"sa":{"href":"http://example.com/{{echo|hi}}"}}'>http://example.com/hi</a>)</p>
4269 <p>(<a rel="mw:ExtLink" href="http://example.com" data-parsoid='{"stx":"url","a":{"href":"http://example.com"},"sa":{"href":"http://example.com<!-- hi -->"}}'>http://example.com</a>)</p>
4279 Normal text. '''Bold text.''' Normal text. ''Italic text.''
4281 Normal text. '''''Bold italic text.''''' Normal text.
4283 <p>Normal text. <b>Bold text.</b> Normal text. <i>Italic text.</i>
4284 </p><p>Normal text. <i><b>Bold italic text.</b></i> Normal text.
4289 # Parsoid inserts an empty bold tag pair at the end of the line, that the PHP
4290 # parser strips. The wikitext contains just the first half of the bold
4293 Unclosed and unmatched quotes
4295 '''''Bold italic text '''with bold deactivated''' in between.'''''
4297 '''''Bold italic text ''with italic deactivated'' in between.'''''
4301 ..spanning two paragraphs (should not work).'''
4303 '''Bold tag left open
4305 ''Italic tag left open
4309 <!-- Unmatching number of opening, closing tags: -->
4310 '''This year''''s election ''should'' beat '''last year''''s.
4312 ''Tom'''s car is bigger than ''Susan'''s.
4314 Plain ''italic'''s plain
4316 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
4317 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
4318 </p><p><b>Bold text..</b>
4319 </p><p>..spanning two paragraphs (should not work).
4320 </p><p><b>Bold tag left open</b>
4321 </p><p><i>Italic tag left open</i>
4323 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
4324 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
4325 </p><p>Plain <i>italic'</i>s plain
4328 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
4329 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
4330 </p><p><b>Bold text..</b>
4331 </p><p>..spanning two paragraphs (should not work).<b></b>
4332 </p><p><b>Bold tag left open</b>
4333 </p><p><i>Italic tag left open</i>
4335 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
4336 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
4337 </p><p>Plain <i>italic'</i>s plain
4344 ### some content taken from http://meta.wikimedia.org/wiki/MediaWiki_User%27s_Guide:_Using_tables
4347 # This should not produce <table></table> as <table><tr><td></td></tr></table>
4348 # is the bare minimum required by the spec, see:
4349 # http://www.w3.org/TR/xhtml-modularization/dtd_module_defs.html#a_module_Basic_Tables
4350 # Parsoid team replies: empty table tags are legal in HTML5
4352 A table with no data.
4365 A table with stray table end tags on start tag line (wt2html)
4369 {|style="color: red;"|}
4371 {|style="color: red;" |}
4375 {|style="color: red;"|} id="foo"
4379 {|style="color: red;" |} id="foo"
4383 <table style="color: red;"></table>
4385 <table style="color: red;">
4391 <table style="color: red;" id="foo">
4397 <table style="color: red;" id="foo">
4406 A table with no data (take 2)
4414 # A table with nothing but a caption is invalid XHTML, we might want to render
4415 # this as <p>caption</p>
4416 # Parsoid team replies: table with only a caption is legal in HTML5
4418 A table with nothing but a caption
4426 </caption><tr><td></td></tr></table>
4429 <table><caption> caption</caption></table>
4433 A table with caption with default-spaced attributes and a table row
4436 |+ style="color: red;" | caption1
4442 <caption style="color: red;"> caption1
4451 A table with captions with non-default spaced attributes and a table row
4454 |+style="color: red;"|caption2
4455 |+ style="color: red;"| caption3
4461 <caption style="color: red;">caption2
4463 <caption style="color: red;"> caption3
4472 Table td-cell syntax variations
4476 | foo bar foo || baz
4477 | style='color:red;' | baz
4478 | style='color:red;' || baz
4485 <td> foo bar foo </td>
4488 <td style="color:red;"> baz
4490 <td> style='color:red;' </td>
4518 Simple table but with multiple dashes for row wikitext
4536 Multiplication table
4538 {| border="1" cellpadding="2"
4539 |+Multiplication table
4541 ! × !! 1 !! 2 !! 3
4559 <table border="1" cellpadding="2">
4560 <caption>Multiplication table
4607 Accept "||" in table headings
4622 Accept "||" in indented table headings
4632 </th></tr></table></dd></dl>
4637 Accept empty attributes in td/th cells (td/th cells starting with leading ||)
4654 Accept "| !" at start of line in tables (ignore !-attribute)
4658 | !style="color:red" | bar
4670 Allow +/- in 2nd and later cells in a row, in 1st cell when td-attrs are present, or in 1st cell when there is a space between "|" and +/-
4674 |style='color:red;'|+1
4675 |style='color:blue;'|-1
4687 <td style="color:red;">+1
4689 <td style="color:blue;">-1
4713 |rowspan=2| Cell 2, row 1 (and 2)
4724 <td rowspan="2"> Cell 2, row 1 (and 2)
4742 {| bgcolor=#ABCDEF border=2
4747 |the original table again
4755 <table bgcolor="#ABCDEF" border="2">
4763 <td>the original table again
4769 Invalid attributes in table cell (bug 1830)
4783 # The "|}" to close the table is missing from the input, so parsoid's
4784 # *2wt modes will fail.
4786 Table security: embedded pipes (http://lists.wikimedia.org/mailman/htdig/wikitech-l/2006-April/022293.html)
4788 parsoid=wt2html,html2html
4791 | |[ftp://|x||]" onmouseover="alert(document.cookie)">test
4795 <td>[<a rel="nofollow" class="external free" href="ftp://%7Cx">ftp://%7Cx</a></td>
4796 <td>]" onmouseover="alert(document.cookie)">test
4804 <td><a rel="mw:ExtLink" href="ftp://|x||"></a>" onmouseover="alert(document.cookie)">test</td></tr></tbody></table>
4809 Indented table markup mixed with indented pre content (proposed in bug 6200)
4814 Text that should be rendered preformatted
4822 <pre>Text that should be rendered preformatted
4831 Template-generated table cell attributes and cell content
4840 <td style="color: red"> Foo
4842 <td style="color: red"> Foo
4848 Template-generated table cell attributes and cell content (2)
4851 |align=center {{table_attribs}}
4856 <td align="center" style="color: red"> Foo
4862 Template-generated table cell attributes and cell content (3)
4865 |align=center {{table_cells}}
4870 <td align="center" style="color: red"> Foo </td>
4878 Table with row followed by newlines and table heading
4896 Table with empty line following the start tag
4913 # FIXME: Preserve the attribute properly (with an empty string as value) in
4914 # the PHP parser. Parsoid implements the behavior below.
4916 Table attributes with empty value
4926 </td></tr></tbody></table>
4931 Wikitext table with a lot of comments
4954 Wikitext table with double-line table cell
4971 Table cell with a single comment
4987 # The expected HTML structure in this test is debatable. The PHP parser does
4988 # not parse this kind of table at all. The main focus for Parsoid is on
4989 # round-tripping, so this output is ok for now. TODO: revisit!
4991 Wikitext table with html-syntax row
5001 <td>foo</td></tr></tbody></table>
5005 Implicit <td> after a |-
5006 (PHP parser relies on Tidy to add the missing <td> tags)
5008 parsoid=wt2html,wt2wt
5021 Pres should be recognized in an explicit <td> context, but not in an implicit <td> context
5022 (PHP parser relies on Tidy to add the missing <td> tags)
5024 parsoid=wt2html,wt2wt
5036 <tr><td><pre>a</pre></td></tr>
5037 <tr><td> b</td></tr>
5043 Lists should be recognized in an implicit <td> context
5044 (PHP parser relies on Tidy to add the missing <td> tags)
5046 parsoid=wt2html,wt2wt
5063 Parsoid: Round-trip tables directly followed by content (bug 51219)
5065 parsoid=wt2html,wt2wt
5077 <td>foo</td></tr></tbody></table> bar
5081 <td>baz</td></tr></tbody></table><b>quux</b>
5085 Parsoid: Default to a newline after tables in new content (bug 51219)
5092 <nowiki> </nowiki>bar
5099 <tr><td>foo</td></tr></tbody></table> bar
5101 <tr><td>baz</td></tr></tbody></table><b>quux</b>
5105 Parsoid: newline inducing block nodes don't suppress <nowiki>
5120 Plain link, capitalized
5124 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
5129 Plain link, uncapitalized
5133 <p><a href="/wiki/Main_Page" title="Main Page">main Page</a>
5140 [[Main Page|The Main Page]]
5142 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
5147 Piped link with comment in link text
5149 [[Main Page|The Main<!--front--> Page]]
5151 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
5156 Piped link with multiple pipe characters in link text
5158 [[Main Page||The|Main|Page|]]
5160 <p><a href="/wiki/Main_Page" title="Main Page">|The|Main|Page|</a>
5163 <p><a rel="mw:WikiLink" href="Main_Page">|The|Main|Page|</a></p>
5171 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig</a>
5176 Broken link with fragment
5178 [[Zigzagzogzagzig#zug]]
5180 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig#zug</a>
5185 Special page link with fragment
5187 [[Special:Version#anchor]]
5189 <p><a href="/wiki/Special:Version#anchor" title="Special:Version">Special:Version#anchor</a>
5194 Nonexistent special page link with fragment
5196 [[Special:ThisNameWillHopefullyNeverBeUsed#anchor]]
5198 <p><a href="/wiki/Special:ThisNameWillHopefullyNeverBeUsed" class="new" title="Special:ThisNameWillHopefullyNeverBeUsed (page does not exist)">Special:ThisNameWillHopefullyNeverBeUsed#anchor</a>
5205 xxx[[main Page]], xxx[[Main Page]], Xxx[[main Page]] XXX[[main Page]], XXX[[Main Page]]
5207 <p>xxx<a href="/wiki/Main_Page" title="Main Page">main Page</a>, xxx<a href="/wiki/Main_Page" title="Main Page">Main Page</a>, Xxx<a href="/wiki/Main_Page" title="Main Page">main Page</a> XXX<a href="/wiki/Main_Page" title="Main Page">main Page</a>, XXX<a href="/wiki/Main_Page" title="Main Page">Main Page</a>
5214 [[Main Page]]xxx, [[Main Page]]XXX, [[Main Page]]!!!
5216 <p><a href="/wiki/Main_Page" title="Main Page">Main Pagexxx</a>, <a href="/wiki/Main_Page" title="Main Page">Main Page</a>XXX, <a href="/wiki/Main_Page" title="Main Page">Main Page</a>!!!
5227 Bug 43661: Piped links with identical prefixes
5229 [[prefixed article|prefixed articles with spaces]]
5231 [[prefixed article|prefixed articlesaoeu]]
5233 [[Main Page|Main Page test]]
5235 <p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articles with spaces</a>
5236 </p><p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articlesaoeu</a>
5237 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page test</a>
5243 Link with HTML entity in suffix / tail
5245 [[Main Page]]", [[Main Page]]a
5247 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>", <a href="/wiki/Main_Page" title="Main Page">Main Page</a>a
5252 Link with 3 brackets
5261 Link with 4 brackets
5265 <p>[[<a href="/wiki/Main_Page" title="Main Page">Main Page</a>]]
5270 Piped link with 3 brackets
5272 [[[main page|the main page]]]
5274 <p>[[[main page|the main page]]]
5279 Piped link with extlink-like text
5282 [[Main Page|This is a [bar]]]
5284 <p><a href="/wiki/Main_Page" title="Main Page">[bar]</a>
5285 <a href="/wiki/Main_Page" title="Main Page">This is a [bar]</a>
5290 Link with multiple pipes
5292 [[Main Page|The|Main|Page]]
5294 <p><a href="/wiki/Main_Page" title="Main Page">The|Main|Page</a>
5301 [[Talk:Parser testing]], [[Meta:Disclaimers]]
5303 <p><a href="/index.php?title=Talk:Parser_testing&action=edit&redlink=1" class="new" title="Talk:Parser testing (page does not exist)">Talk:Parser testing</a>, <a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">Meta:Disclaimers</a>
5308 MemoryAlpha:AlphaTest
5310 This is an article in the MemoryAlpha namespace
5311 (which shadows the memoryalpha interwiki link).
5315 Namespace takes precedence over interwiki link (bug 51680)
5317 [[MemoryAlpha:AlphaTest]]
5319 <p><a href="/wiki/MemoryAlpha:AlphaTest" title="MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a>
5323 # The previous test doesn't work correctly in html2*, due to not recognizing the
5324 # link as an internal one. This one checks for the correct behavior.
5326 Link to namespace preferred over interwiki with correct rel attribute
5328 parsoid=html2wt,html2html
5330 [[MemoryAlpha:AlphaTest]]
5332 <p><a rel="mw:WikiLink" href="./MemoryAlpha:AlphaTest">MemoryAlpha:AlphaTest</a>
5337 Piped link to namespace
5339 [[Meta:Disclaimers|The disclaimers]]
5341 <p><a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">The disclaimers</a>
5348 [[Usually caused by a typo (oops}]]
5350 <p>[[Usually caused by a typo (oops}]]
5357 Just a test of an article title containing a percent.
5361 Link containing % (not as a hex sequence)
5365 <p><a href="/wiki/7%25_Solution" title="7% Solution">7% Solution</a>
5368 <p><a rel="mw:WikiLink" href="./7%25_Solution">7% Solution</a></p>
5371 # note that the parsoid HTML is identical to the previous test output,
5372 # so the previous test ensures that the html2wt mode will generate the
5373 # "not as a hex sequence" wikitext.
5375 Link containing % as a single hex sequence interpreted to char
5377 parsoid=wt2wt,wt2html,html2html
5381 <p><a href="/wiki/7%25_Solution" title="7% Solution">7% Solution</a>
5384 <p><a rel="mw:WikiLink" href="./7%25_Solution">7% Solution</a></p>
5388 Link containing % as a double hex sequence interpreted to hex sequence
5392 <p>[[7%2525 Solution]]
5396 # note that parsoid does not munge anchor text; all non-space
5397 # characters are valid in HTML5 anchors.
5399 Link containing "#<" and "#>" % as a hex sequences- these are valid section anchors
5400 Example for such a section: == < ==
5402 [[%23%3c]][[%23%3e]]
5404 <p><a href="#.3C">#<</a><a href="#.3E">#></a>
5407 <p><a rel="mw:WikiLink" href="./Main%20Page#%3C">#<</a><a rel="mw:WikiLink" href="./Main%20Page#%3E">#></a></p>
5411 Link containing "<#" and ">#" as a hex sequences
5413 [[%3c%23]][[%3e%23]]
5415 <p>[[%3c%23]][[%3e%23]]
5420 Link containing an equals sign
5422 [[Special:BookSources/isbn=4-00-026157-6]]
5424 <p><a href="/wiki/Special:BookSources/isbn%3D4-00-026157-6" title="Special:BookSources/isbn=4-00-026157-6">Special:BookSources/isbn=4-00-026157-6</a>
5427 <p><a rel="mw:WikiLink" href="./Special:BookSources/isbn=4-00-026157-6">Special:BookSources/isbn=4-00-026157-6</a></p>
5433 Just a test of an article title containing a tilde.
5436 # note that links containing signatures, like [[Foo~~~~]], are
5437 # massaged by the pre-save transform (PST) and so the tildes are never
5438 # seen by the parser.
5440 Link containing a tilde
5444 <p><a href="/wiki/Foo%7Ebar" title="Foo~bar">Foo~bar</a>
5447 <p><a rel="mw:WikiLink" href="./Foo~bar">Foo~bar</a></p>
5451 Link containing double-single-quotes '' (bug 4598)
5453 [[Lista d''e paise d''o munno]]
5455 <p><a href="/index.php?title=Lista_d%27%27e_paise_d%27%27o_munno&action=edit&redlink=1" class="new" title="Lista d''e paise d''o munno (page does not exist)">Lista d''e paise d''o munno</a>
5458 <p><a rel="mw:WikiLink" href="./Lista_d''e_paise_d''o_munno">Lista d''e paise d''o munno</a></p>
5462 Link containing double-single-quotes '' in text (bug 4598 sanity check)
5464 Some [[Link|pretty ''italics'' and stuff]]!
5466 <p>Some <a href="/index.php?title=Link&action=edit&redlink=1" class="new" title="Link (page does not exist)">pretty <i>italics</i> and stuff</a>!
5469 <p>Some <a rel="mw:WikiLink" href="Link">pretty <i>italics</i> and stuff</a>!</p>
5473 Link containing double-single-quotes '' in text embedded in italics (bug 4598 sanity check)
5475 ''Some [[Link|pretty ''italics'' and stuff]]!''
5477 <p><i>Some <a href="/index.php?title=Link&action=edit&redlink=1" class="new" title="Link (page does not exist)">pretty <i>italics</i> and stuff</a>!</i>
5482 Link with double quotes in title part (literal) and alternate part (interpreted)
5484 [[File:Denys Savchenko ''Pentecoste''.jpg]]
5488 [[''Pentecoste''|Pentecoste]]
5490 [[''Pentecoste''|''Pentecoste'']]
5492 <p><a href="/index.php?title=Special:Upload&wpDestFile=Denys_Savchenko_%27%27Pentecoste%27%27.jpg" class="new" title="File:Denys Savchenko ''Pentecoste''.jpg">File:Denys Savchenko <i>Pentecoste</i>.jpg</a>
5493 </p><p><a href="/index.php?title=%27%27Pentecoste%27%27&action=edit&redlink=1" class="new" title="''Pentecoste'' (page does not exist)">''Pentecoste''</a>
5494 </p><p><a href="/index.php?title=%27%27Pentecoste%27%27&action=edit&redlink=1" class="new" title="''Pentecoste'' (page does not exist)">Pentecoste</a>
5495 </p><p><a href="/index.php?title=%27%27Pentecoste%27%27&action=edit&redlink=1" class="new" title="''Pentecoste'' (page does not exist)"><i>Pentecoste</i></a>
5498 <meta typeof="mw:Placeholder"/>
5499 <p><a rel="mw:WikiLink" href="''Pentecoste''">''Pentecoste''</a></p>
5500 <p><a rel="mw:WikiLink" href="''Pentecoste''">Pentecoste</a></p>
5501 <p><a rel="mw:WikiLink" href="''Pentecoste''"><i>Pentecoste</i></a></p>
5505 Broken image links with HTML captions (bug 39700)
5507 [[File:Nonexistent|<script></script>]]
5508 [[File:Nonexistent|100px|<script></script>]]
5509 [[File:Nonexistent|<]]
5510 [[File:Nonexistent|a<i>b</i>c]]
5512 <p><a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
5513 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
5514 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><</a>
5515 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent">abc</a>
5522 [[http://www.example.com]]
5524 <p>[<a rel="nofollow" class="external autonumber" href="http://www.example.com">[1]</a>]
5527 <p>[<a rel="mw:ExtLink" href="http://www.example.com"></a>]</p>
5531 Plain link to URL with link text
5533 [[http://www.example.com Link text]]
5535 <p>[<a rel="nofollow" class="external text" href="http://www.example.com">Link text</a>]
5540 Plain link to protocol-relative URL
5542 [[//www.example.com]]
5544 <p>[<a rel="nofollow" class="external autonumber" href="//www.example.com">[1]</a>]
5547 <p>[<a rel="mw:ExtLink" href="//www.example.com"></a>]</p>
5551 Plain link to protocol-relative URL with link text
5553 [[//www.example.com Link text]]
5555 <p>[<a rel="nofollow" class="external text" href="//www.example.com">Link text</a>]
5560 Plain link to page with question mark in title
5566 <p><a href="/wiki/A%3Fb" title="A?b">A?b</a>
5567 </p><p><a href="/wiki/A%3Fb" title="A?b">Baz</a>
5572 # I'm fairly sure the expected result here is wrong.
5573 # We want these to be URL links, not pseudo-pages with URLs for titles....
5574 # However the current output is also pretty screwy.
5577 # I'm changing it to match the current output--it arguably makes more
5578 # sense in the light of the test above. Old expected result was:
5579 #<p>Piped link to URL: <a href="/index.php?title=Http://www.example.com&action=edit" class="new">an example URL</a>
5581 # But I think this test is bordering on "garbage in, garbage out" anyway.
5586 Piped link to URL: [[http://www.example.com|an example URL]]
5588 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
5591 <p>Piped link to URL: [<a rel="mw:ExtLink" href="http://www.example.com|an">example URL</a>]</p>
5595 BUG 2: [[page|http://url/]] should link to page, not http://url/
5597 [[Main Page|http://url/]]
5599 <p><a href="/wiki/Main_Page" title="Main Page">http://url/</a>
5602 <p><a rel="mw:WikiLink" href="./Main_Page">http://url/</a></p>
5605 # Parsoid does not mark self-links, by design.
5607 BUG 337: Escaped self-links should be bold
5611 [[Bug462]] [[Bug462]]
5613 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong>
5616 <p><a rel="mw:WikiLink" href="./Bug462">Bug462</a> <a rel="mw:WikiLink" href="./Bug462">Bug462</a></p>
5620 Self-link to section should not be bold
5624 [[Main Page#section]]
5626 <p><a href="/wiki/Main_Page#section" title="Main Page">Main Page#section</a>
5637 Self-link to numeric title
5643 <p><strong class="selflink">0</strong>
5648 Link to numeric-equivalent title
5654 <p><a href="/wiki/00" title="00">00</a>
5659 <nowiki> inside a link
5661 [[Main<nowiki> Page</nowiki>]] [[Main Page|the main page <nowiki>[it's not very good]</nowiki>]]
5663 <p>[[Main Page]] <a href="/wiki/Main_Page" title="Main Page">the main page [it's not very good]</a>
5668 Non-breaking spaces in title
5670 [[ Main Page ]]
5672 <p><a href="/wiki/Main_Page" title="Main Page">  Main   Page  </a>
5677 Internal link with ca linktrail, surrounded by bold apostrophes (bug 27473 primary issue)
5683 <p><b><a href="/wiki/Main_Page" title="Main Page">Main Page</a></b>
5688 Internal link with ca linktrail, surrounded by italic apostrophes (bug 27473 primary issue)
5694 <p><i><a href="/wiki/Main_Page" title="Main Page">Main Page</a></i>
5699 Internal link with en linktrail: no apostrophes (bug 27473)
5705 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (page does not exist)">Something</a>'nice
5710 Internal link with ca linktrail with apostrophes (bug 27473)
5716 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (encara no existeix)">Something'nice</a>
5721 Internal link with kaa linktrail with apostrophes (bug 27473)
5727 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (bet ele jaratılmag'an)">Something'nice</a>
5732 Link with multiple ":" in a subpage-supporting namespace (bug 63636)
5734 [[User:Foo/Test/63636:Bar|Test]]
5736 <p><a href="/index.php?title=User:Foo/Test/63636:Bar&action=edit&redlink=1" class="new" title="User:Foo/Test/63636:Bar (page does not exist)">Test</a>
5739 <p><a rel="mw:WikiLink" href="./User:Foo/Test/63636:Bar">Test</a></p>
5743 1. Interaction of linktrail and template encapsulation
5749 <p><a rel="mw:WikiLink" href="Foo" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[[Foo]]"}},"i":0}},"l"]}'>Fool</a></p>
5753 2. Interaction of linktrail and template encapsulation
5757 {{echo|Some [[Fool]]}}s
5759 <p data-parsoid='{}'><span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Some [[Fool]]"}},"i":0}},"s"]}' data-parsoid='{"pi":[[{"k":"1","spc":["","","",""]}]]}'>Some </span><a rel="mw:WikiLink" href="./Fool" about="#mwt1" data-parsoid='{"stx":"simple","a":{"href":"./Fool"},"sa":{"href":"Fool"},"tail":"s"}'>Fools</a></p>
5763 3. Interaction of linktrail and template encapsulation
5767 {{echo|Some [[Fool]]s are '''bold and foolish'''}}
5769 <p about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Some [[Fool]]s are '''bold and foolish'''"}},"i":0}}]}' data-parsoid='{"pi":[[{"k":"1","spc":["","","",""]}]]}'>Some <a rel="mw:WikiLink" href="./Fool" data-parsoid='{"stx":"simple","a":{"href":"./Fool"},"sa":{"href":"Fool"},"tail":"s"}'>Fools</a> are <b data-parsoid="{}">bold and foolish</b></p>
5779 Internal link with is link prefix
5783 Aðrir mótmælenda[[söfnuður|söfnuðir]] og
5785 <p>Aðrir <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a> og
5796 Internal link with is link trail and link prefix
5800 [[mótmælendatrú|xxx]]ar
5802 mótmælenda[[söfnuður]]
5803 mótmælenda[[söfnuður|söfnuðir]]
5804 mótmælenda[[söfnuður|söfnuðir]]xxx
5806 <p><a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">xxxar</a>
5807 <a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">mótmælendatrúar</a>
5808 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuður</a>
5809 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a>
5810 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðirxxx</a>
5815 Parsoid link trail escaping
5817 parsoid=html2wt,html2html
5821 <p><a rel="mw:WikiLink" href="Apple">apple</a>s</p>
5825 Parsoid link prefix escaping
5828 parsoid=html2wt,html2html
5830 Aðrir mótmælenda<nowiki/>[[söfnuður]]
5832 <p>Aðrir mótmælenda<a rel="mw:WikiLink" href="Söfnuður">söfnuður</a></p>
5836 Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
5844 [http://wp.org ''foo'']
5846 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> bar</a>
5847 </p><p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> <i>bar</i></a>
5848 </p><p><a rel="nofollow" class="external text" href="http://wp.org">foo</a>
5849 </p><p><a rel="nofollow" class="external text" href="http://wp.org"><i>foo</i></a>
5854 Parsoid: Scoped parsing should handle mixed transclusions and plain text
5858 [[Foo|{{echo|a}} b {{echo|c}}]]
5860 <p><a rel="mw:WikiLink" href="Foo"><span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a"}},"i":0}}]}'>a</span> b <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"c"}},"i":0}}]}'>c</span></a></p>
5864 ### Interwiki links (see maintenance/interwiki.sql)
5868 Inline interwiki link
5870 [[MeatBall:SoftSecurity]]
5872 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a>
5877 Inline interwiki link with empty title (bug 2372)
5881 <p><a href="http://www.usemod.com/cgi-bin/mb.pl" class="extiw" title="meatball:">MeatBall:</a>
5886 Interwiki link encoding conversion (bug 1636)
5888 *[[Wikipedia:ro:Olteniţa]]
5889 *[[Wikipedia:ro:Olteniţa]]
5891 <ul><li><a href="http://en.wikipedia.org/wiki/ro:Olteni%C5%A3a" class="extiw" title="wikipedia:ro:Olteniţa">Wikipedia:ro:Olteniţa</a></li>
5892 <li><a href="http://en.wikipedia.org/wiki/ro:Olteni%C5%A3a" class="extiw" title="wikipedia:ro:Olteniţa">Wikipedia:ro:Olteniţa</a></li></ul>
5897 Interwiki link with fragment (bug 2130)
5899 [[MeatBall:SoftSecurity#foo]]
5901 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity#foo" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity#foo</a>
5905 # Ideally the wikipedia: prefix here should be proto-relative too
5907 Different interwiki prefixes mapping to the same URL
5915 [[:wikipedia:Foo|Foo]]
5917 [[wikipedia:en:Foo]]
5919 [[:wikipedia:en:Foo]]
5921 <p><a rel="mw:ExtLink" href="//en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"simple","a":{"href":"//en.wikipedia.org/wiki/Foo"},"sa":{"href":":en:Foo"},"isIW":true}'>en:Foo</a></p>
5923 <p><a rel="mw:ExtLink" href="//en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"//en.wikipedia.org/wiki/Foo"},"sa":{"href":":en:Foo"},"isIW":true}'>Foo</a></p>
5925 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":"wikipedia:Foo"},"isIW":true}'>wikipedia:Foo</a></p>
5927 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":":wikipedia:Foo"},"isIW":true}'>Foo</a></p>
5929 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/en:Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/en:Foo"},"sa":{"href":"wikipedia:en:Foo"},"isIW":true}'>wikipedia:en:Foo</a></p>
5931 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/en:Foo" data-parsoid='{"stx":"simple","a":{"href":"http://en.wikipedia.org/wiki/en:Foo"},"sa":{"href":":wikipedia:en:Foo"},"isIW":true}'>wikipedia:en:Foo</a></p>
5935 Interwiki links that cannot be represented in wiki syntax
5938 [[meatball:ok#foo|ok with fragment]]
5939 [[meatball:ok_as_well?|ok ending with ? mark]]
5940 [http://de.wikipedia.org/wiki/Foo?action=history has query]
5941 [http://de.wikipedia.org/wiki/#foo is just fragment]
5944 <p><a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok">meatball:ok</a>
5945 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok#foo">ok with fragment</a>
5946 <a rel="mw:ExtLink" href="http://www.usemod.com/cgi-bin/mb.pl?ok_as_well?">ok ending with ? mark</a>
5947 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/Foo?action=history">has query</a>
5948 <a rel="mw:ExtLink" href="http://de.wikipedia.org/wiki/#foo">is just fragment</a></p>
5952 Interwiki links: trail
5956 [[wikipedia:Foo|Ba]]r
5958 <p data-parsoid='{}'><a rel="mw:ExtLink" href="http://en.wikipedia.org/wiki/Foo" data-parsoid='{"stx":"piped","a":{"href":"http://en.wikipedia.org/wiki/Foo"},"sa":{"href":"wikipedia:Foo"},"isIW":true,"tail":"r"}'>Bar</a></p>
5962 ### Interlanguage links
5963 ### Language links (so that searching for '### language' matches..)
5977 Double interlanguage link
5988 Interlanguage link, with prefix links
6000 Double interlanguage link, with prefix links (bug 8897)
6013 Parsoid-specific test: Wikilinks with should RT properly
6019 <p><a href="/index.php?title=WW_II&action=edit&redlink=1" class="new" title="WW II (lonkásá ezalí tɛ̂)">WW II</a>
6024 Parsoid bug 53221: Wikilinks should be properly entity-escaped
6028 He&nbsp;llo [[Foo|He&nbsp;llo]]
6030 He&nbsp;llo [[He&nbsp;llo]]
6032 <p>He&nbsp;llo <a href="Foo" rel="mw:WikiLink">He&nbsp;llo</a></p>
6033 <p>He&nbsp;llo <a href="He&nbsp;llo" rel="mw:WikiLink">He&nbsp;llo</a></p>
6037 Parsoid: handle constructor well
6045 <p><a rel="mw:WikiLink" href="./Constructor" data-parsoid="{"stx":"simple","a":{"href":"./Constructor"},"sa":{"href":"constructor"}}">constructor</a></p>
6047 <p><a rel="mw:WikiLink" href="./Foo" data-parsoid="{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"constructor:foo"}}">constructor:foo</a></p>
6051 Parsoid: recognize interlanguage links without a target page
6058 <link rel="mw:PageProp/Language" href="http://ko.wikipedia.org/wiki/"></p>
6062 Parsoid: recognize interwiki links without a target page
6068 <p><a rel="mw:ExtLink" href="//ko.wikipedia.org/wiki/">ko:</a></p>
6072 Parsoid: Bug #45209, handle interwiki links pointing to the current wiki as plain wiki links
6078 <p><a rel="mw:WikiLink" href="./Foo" data-parsoid='{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"en:Foo"}}'>Foo</a></p>
6082 ### Redirects, Parsoid-only
6085 1. Simple redirect to page
6089 #REDIRECT [[Main Page]]
6091 <link rel="mw:PageProp/redirect" href="./Main_Page">
6094 # Only wt2html and html2html since "Main_Page" will serialize to "Main Page"
6096 2. Other redirect variants
6098 parsoid=wt2html,wt2wt
6100 #REDIRECT [[Main_Page]]
6101 #REDIRECT [[<nowiki>[[Bar]]</nowiki>]]
6103 <link rel="mw:PageProp/redirect" href="./Main_Page">
6104 <link rel="mw:PageProp/redirect" href="./%5B%5BBar%5D%5D">
6108 Optional colon in #REDIRECT
6110 # the colon is archaic syntax. we support it for wt2html, but we
6111 # don't care that it roundtrips back to the modern syntax.
6112 parsoid=wt2html,html2html
6114 #REDIRECT:[[Main Page]]
6116 <link rel="mw:PageProp/redirect" href="./Main_Page">
6120 Whitespace in #REDIRECT with optional colon
6122 # the colon and gratuitous whitespace is archaic syntax. we support
6123 # it for wt2html, but we don't care that it roundtrips back to the
6124 # modern syntax (without extra whitespace)
6125 parsoid=wt2html,html2html
6132 <link rel="mw:PageProp/redirect" href="./Main_Page">
6136 Piped link in #REDIRECT
6138 # content after piped link is ignored. we support this syntax,
6139 # but don't care that the piped link is lost when we roundtrip this.
6142 #REDIRECT [[Main Page|bar]]
6144 <link rel="mw:PageProp/redirect" href="./Main_Page">
6148 Redirect to category
6152 #REDIRECT [[Category:Foo]]
6154 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:PageProp/Category" href="./Category:Foo">
6158 Redirect to category with URL encoding
6162 #REDIRECT [[Category%3AFoo]]
6164 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:PageProp/Category" href="./Category:Foo">
6168 Redirect to category page
6170 parsoid=wt2html,html2html
6172 #REDIRECT [[:Category:Foo]]
6174 <p><a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a></p>
6178 Redirect to image page (1)
6182 #REDIRECT [[File:Wiki.png]]
6184 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
6188 Redirect to image page (2)
6192 #REDIRECT [[Image:Wiki.png]]
6194 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
6198 Redirect to language
6202 #REDIRECT [[en:File:Wiki.png]]
6204 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
6208 Redirect to interwiki
6212 #REDIRECT [[meatball:File:Wiki.png]]
6214 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
6218 Non-English #REDIRECT
6223 #TILVÍSUN [[Main Page]]
6225 <link rel="mw:PageProp/redirect" href="./Main_Page">
6236 <p>Foo<link rel="mw:PageProp/redirect" href="./Foo"></p>
6253 Broken br tag sanitization
6261 # TODO: Fix html2html mode (bug 51055)!
6263 Parsoid: Broken br tag recognition
6273 Incorrecly removing closing slashes from correctly formed XHTML
6275 <br style="clear:both;" />
6277 <p><br style="clear:both;" />
6282 Failing to transform badly formed HTML into correct XHTML
6284 <br style="clear: left;">
6285 <br style="clear: right;">
6286 <br style="clear: both;">
6288 <p><br style="clear: left;" />
6289 <br style="clear: right;" />
6290 <br style="clear: both;" />
6295 Handling html with a div self-closing tag
6304 <p><div title />
6308 <p><div title=bar />
6309 <div title=bar/>
6311 <div title="bar/"></div>
6317 Handling html with a br self-closing tag
6326 <p><br title="title" />
6327 <br title="title" />
6336 Horizontal ruler (should it add that extra space?)
6350 Horizontal ruler -- 4+ dashes render hr
6359 Horizontal ruler -- eats additional dashes on the same line
6368 Horizontal ruler -- does not collapse dashes on consecutive lines
6379 Horizontal ruler -- <4 dashes render as plain text
6388 Horizontal ruler -- Supports content following dashes on same line
6397 ### Block-level elements
6406 <ul><li>Common list</li>
6408 <li>item 3</li></ul>
6419 <ol><li>Numbered list</li>
6421 <li> item 3</li></ol>
6435 ***#Number on level 4
6437 **#Number on level 3
6438 **#Number on level 3
6442 #** Level 3, but ordered
6445 <ol><li> with numbers</li></ol>
6446 <ul><li> and bullets</li></ul>
6447 <ol><li> and numbers</li></ol></li>
6449 <ul><li>bullet level 2
6450 <ul><li>bullet level 3
6451 <ol><li>Number on level 4</li></ol></li></ul></li>
6453 <ol><li>Number on level 3</li>
6454 <li>Number on level 3</li></ol></li></ul>
6455 <ol><li>number level 2</li></ol></li>
6457 <ul><li><ul><li> Level 3</li></ul></li></ul></li></ul>
6458 <ol><li><ul><li><ul><li> Level 3, but ordered</li></ul></li></ul></li></ol>
6469 <ul><li>bar</li></ul></li></ul>
6479 <ul><li><ul><li>foo</li></ul></li>
6485 Nested lists 3 (first element empty)
6491 <ul><li>bar</li></ul></li></ul>
6496 Nested lists 4 (first element empty)
6501 <ul><li><ul><li></li></ul></li>
6507 Nested lists 5 (both elements empty)
6512 <ul><li><ul><li></li></ul></li>
6518 Nested lists 6 (both elements empty)
6524 <ul><li></li></ul></li></ul>
6529 Nested lists 7 (skip initial nesting levels)
6533 <ul><li><ul><li><ul><li> foo</li></ul></li></ul></li></ul>
6538 Nested lists 8 (multiple nesting transitions)
6546 <ul><li><ul><li> bar</li></ul></li>
6547 <li> baz</li></ul></li>
6553 1. Lists with start-of-line-transparent tokens before bullets: Comments
6566 2. Lists with start-of-line-transparent tokens before bullets: Template close
6571 <ul><li>foo bar</li>
6577 List items are not parsed correctly following a <pre> block (bug 785)
6583 <ul><li> <pre>foo</pre></li>
6584 <li> <pre>bar</pre></li>
6590 List items from template
6601 * notSOL{{inner list}}
6604 <ul><li> item 1</li>
6605 <li> item 2</li></ul>
6606 <ul><li> item 0</li>
6608 <li> item 2</li></ul>
6609 <ul><li> item 0</li>
6612 <li> item 2</li></ul>
6617 List interrupted by empty line or heading
6625 <ul><li> foo</li></ul>
6626 <ul><li><ul><li> bar</li></ul></li></ul>
6627 <h2><span class="mw-headline" id="A_heading">A heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: A heading">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
6628 <ul><li> Another list item</li></ul>
6633 Multiple list tags generated by templates
6648 Single-comment whitespace lines dont break lists, and neither do multi-comment whitespace lines
6651 <!--This line will NOT split the list-->
6653 <!--This line will NOT split the list either-->
6655 <!--foo--> <!----> <!--This line NOT split the list either-->
6666 Replacing whitespace with tabs still doesn't break the list (gerrit 78327)
6669 <!--This line will NOT split the list-->
6671 <!--This line will NOT split the list either-->
6673 <!--foo--> <!----> <!--This line NOT split the list
6686 (Cannot test this with PHP parser since it relies on Tidy for the hack)
6688 parsoid=wt2html,wt2wt
6692 * {{echo|<li>templated li-hack}}
6693 * <!--foo--> <li> unsupported li-hack with preceding comments
6696 <li><li>not a li-hack
6703 <li about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<li>templated li-hack"}}}}]}'>templated li-hack</li>
6704 <li> <!--foo--> </li>
6705 <li> li-hack with preceding comments</li>
6716 Parsoid: Make sure nested lists are serialized on their own line even if HTML contains no newlines
6743 Parsoid: Test of whitespace serialization with Templated bullets
6750 <li> </li><li about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"bullet","href":"./Template:Bullet"},"params":{},"i":0}}]}'> Bar</li>
6754 # ------------------------------------------------------------------------
6755 # The next set of tests are about Parsoid's ability to handle badly nested
6756 # tags (parse, minimize scope of fixup, and roundtrip back)
6757 # ------------------------------------------------------------------------
6760 Unbalanced closing block tags break a list
6761 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
6779 Unbalanced closing non-block tags don't break a list
6780 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
6797 Unclosed formatting tags that straddle lists are closed and reopened
6798 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
6812 List embedded in a non-block tag
6813 (Ugly Parsoid output -- worth fixing; Disabled for PHP parser since it relies on Tidy)
6819 <p><small></small></p>
6825 <p><small></small></p>
6829 Table with missing opening <tr> tag
6831 parsoid=wt2html,wt2wt
6849 # Note that the current date is hard-coded as
6850 # 1970-01-01T00:02:03Z (a Thursday)
6851 # when running parser tests. The timezone is also fixed to GMT, so
6852 # local date will be identical to current date.
6855 Magic Word: {{CURRENTDAY}}
6864 Magic Word: {{CURRENTDAY2}}
6873 Magic Word: {{CURRENTDAYNAME}}
6882 Magic Word: {{CURRENTDOW}}
6891 Magic Word: {{CURRENTMONTH}}
6900 Magic Word: {{CURRENTMONTH1}}
6909 Magic Word: {{CURRENTMONTHABBREV}}
6911 {{CURRENTMONTHABBREV}}
6918 Magic Word: {{CURRENTMONTHNAME}}
6920 {{CURRENTMONTHNAME}}
6927 Magic Word: {{CURRENTMONTHNAMEGEN}}
6929 {{CURRENTMONTHNAMEGEN}}
6936 Magic Word: {{CURRENTTIME}}
6945 Magic Word: {{CURRENTHOUR}}
6954 Magic Word: {{CURRENTWEEK}} (@bug 4594)
6963 Magic Word: {{CURRENTYEAR}}
6972 Magic Word: {{CURRENTTIMESTAMP}}
6974 {{CURRENTTIMESTAMP}}
6981 Magic Words LOCAL (UTC)
6985 * {{LOCALMONTHNAME}}
6986 * {{LOCALMONTHNAMEGEN}}
6987 * {{LOCALMONTHABBREV}}
6996 * {{LOCALTIMESTAMP}}
7011 <li> 19700101000203</li></ul>
7016 Magic Word: {{FULLPAGENAME}}
7018 title=[[User:Ævar Arnfjörð Bjarmason]]
7022 <p>User:Ævar Arnfjörð Bjarmason
7027 Magic Word: {{FULLPAGENAMEE}}
7029 title=[[User:Ævar Arnfjörð Bjarmason]]
7033 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7038 Magic Word: {{TALKSPACE}}
7040 title=[[User:Ævar Arnfjörð Bjarmason]]
7049 Magic Word: {{TALKSPACE}}, same namespace
7051 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7060 Magic Word: {{TALKSPACE}}, main namespace
7062 title=[[Parser Test]]
7071 Magic Word: {{TALKSPACEE}}
7073 title=[[User:Ævar Arnfjörð Bjarmason]]
7082 Magic Word: {{SUBJECTSPACE}}
7084 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7093 Magic Word: {{SUBJECTSPACE}}, same namespace
7095 title=[[User:Ævar Arnfjörð Bjarmason]]
7104 Magic Word: {{SUBJECTSPACE}}, main namespace
7106 title=[[Parser Test]]
7114 Magic Word: {{SUBJECTSPACEE}}
7116 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7125 Magic Word: {{NAMESPACE}}
7127 title=[[User:Ævar Arnfjörð Bjarmason]]
7136 Magic Word: {{NAMESPACEE}}
7138 title=[[User:Ævar Arnfjörð Bjarmason]]
7147 Magic Word: {{NAMESPACENUMBER}}
7149 title=[[User:Ævar Arnfjörð Bjarmason]]
7158 Magic Word: {{SUBPAGENAME}}
7160 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
7169 Magic Word: {{SUBPAGENAMEE}}
7171 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
7180 Magic Word: {{ROOTPAGENAME}}
7182 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
7186 <p>Ævar Arnfjörð Bjarmason
7191 Magic Word: {{ROOTPAGENAMEE}}
7193 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
7197 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7202 Magic Word: {{BASEPAGENAME}}
7204 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
7208 <p>Ævar Arnfjörð Bjarmason
7213 Magic Word: {{BASEPAGENAMEE}}
7215 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
7219 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7224 Magic Word: {{TALKPAGENAME}}
7226 title=[[User:Ævar Arnfjörð Bjarmason]]
7230 <p>User talk:Ævar Arnfjörð Bjarmason
7235 Magic Word: {{TALKPAGENAMEE}}
7237 title=[[User:Ævar Arnfjörð Bjarmason]]
7241 <p>User_talk:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7246 Magic Word: {{SUBJECTPAGENAME}}
7248 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7252 <p>User:Ævar Arnfjörð Bjarmason
7257 Magic Word: {{SUBJECTPAGENAMEE}}
7259 title=[[User talk:Ævar Arnfjörð Bjarmason]]
7261 {{SUBJECTPAGENAMEE}}
7263 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7268 Magic Word: {{NUMBEROFFILES}}
7277 Magic Word: {{PAGENAME}}
7279 title=[[User:Ævar Arnfjörð Bjarmason]]
7283 <p>Ævar Arnfjörð Bjarmason
7288 Magic Word: {{PAGENAME}} with metacharacters
7290 title=[['foo & bar = baz']]
7294 <p><i>'foo & bar = baz'</i>
7299 Magic Word: {{PAGENAME}} with metacharacters (bug 26781)
7301 title=[[*RFC 1234 http://example.com/]]
7305 <p>*RFC 1234 http://example.com/
7310 Magic Word: {{PAGENAMEE}}
7312 title=[[User:Ævar Arnfjörð Bjarmason]]
7316 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
7321 Magic Word: {{PAGENAMEE}} with metacharacters (bug 26781)
7323 title=[[*RFC 1234 http://example.com/]]
7327 <p>*RFC_1234_http://example.com/
7332 Magic Word: {{REVISIONID}}
7341 Magic Word: {{SCRIPTPATH}}
7350 Magic Word: {{STYLEPATH}}
7359 Magic Word: {{SERVER}}
7363 <p><a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
7368 Magic Word: {{SERVERNAME}}
7377 Magic Word: {{SITENAME}}
7386 Case-sensitive magic words, when cased differently, should just be template transclusions
7393 <p><a href="/index.php?title=Template:CurrentMonth&action=edit&redlink=1" class="new" title="Template:CurrentMonth (page does not exist)">Template:CurrentMonth</a>
7394 <a href="/index.php?title=Template:Currentday&action=edit&redlink=1" class="new" title="Template:Currentday (page does not exist)">Template:Currentday</a>
7395 <a href="/index.php?title=Template:CURreNTweEK&action=edit&redlink=1" class="new" title="Template:CURreNTweEK (page does not exist)">Template:CURreNTweEK</a>
7396 <a href="/index.php?title=Template:CurrentHour&action=edit&redlink=1" class="new" title="Template:CurrentHour (page does not exist)">Template:CurrentHour</a>
7401 Case-insensitive magic words should still work with weird casing.
7411 <a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
7416 Namespace 1 {{ns:1}}
7425 Namespace 1 {{ns:01}}
7434 Namespace 0 {{ns:0}} (bug 4783)
7442 Namespace 0 {{ns:00}} (bug 4783)
7450 Namespace -1 {{ns:-1}}
7459 Namespace User {{ns:User}}
7468 Namespace User talk {{ns:User_talk}}
7477 Namespace User talk {{ns:uSeR tAlK}}
7486 Namespace File {{ns:File}}
7495 Namespace File {{ns:Image}}
7504 Namespace (lang=de) Benutzer {{ns:User}}
7515 Namespace (lang=de) Benutzer Diskussion {{ns:3}}
7521 <p>Benutzer Diskussion
7529 {{urlencode:hi world?!}}
7530 {{urlencode:hi world?!|WIKI}}
7531 {{urlencode:hi world?!|PATH}}
7532 {{urlencode:hi world?!|QUERY}}
7542 Magic Word: prioritize type info over data-parsoid
7548 <meta property="mw:PageProp/forcetoc" data-parsoid='{"src":"__NOTOC__","magicSrc":"__NOTOC__"}'/>
7552 Magic Word: serialize on separate line (parsoid)
7554 parsoid=wt2wt,html2wt
7560 foo<meta property="mw:PageProp/notoc"/>bar
7564 Magic Word: rt non-english wikis
7571 <meta property="mw:PageProp/noeditsection" data-parsoid='{"src":"__NOEDITSECTION__","magicSrc":"__NOEDITSECTION__"}'/>
7578 Magic links: internal link to RFC (bug 479)
7582 <p><a href="/index.php?title=RFC_123&action=edit&redlink=1" class="new" title="RFC 123 (page does not exist)">RFC 123</a>
7587 Magic links: RFC (bug 479)
7591 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
7596 Magic links: ISBN (bug 1937)
7600 <p><a href="/wiki/Special:BookSources/0306406152" class="internal mw-magiclink-isbn">ISBN 0-306-40615-2</a>
7605 Magic links: PMID incorrectly converts space to underscore
7609 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
7618 Nonexistent template
7620 {{thistemplatedoesnotexist}}
7622 <p><a href="/index.php?title=Template:Thistemplatedoesnotexist&action=edit&redlink=1" class="new" title="Template:Thistemplatedoesnotexist (page does not exist)">Template:Thistemplatedoesnotexist</a>
7627 Template with invalid target containing tags
7629 {{a<b>b</b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
7631 <p>{{a<b>b</b>|foo|a=b|a = b}}
7636 Template with invalid target containing unclosed tag
7638 {{a<b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
7640 <p>{{a<b>|foo|a=b|a = b}}</b>
7645 Template with invalid target containing wikilink
7649 <p>{{<a href="/wiki/Main_Page" title="Main Page">Main Page</a>}}
7652 <p><span typeof="mw:Transclusion" about="#mwt1" data-mw='{"parts":[{"template":{"target":{"wt":"[[Main Page]]"},"params":{},"i":0}}]}'>{{</span><a rel="mw:WikiLink" href="./Main_Page" about="#mwt1">Main Page</a><span about="#mwt1">}}</span></p>
7658 This is a test template
7666 <p>This is a test template
7671 Template with explicit namespace
7675 <p>This is a test template
7683 This is a test template with parameter {{{param}}}
7689 {{paramtest|param=foo}}
7691 <p>This is a test template with parameter foo
7696 Template:paramtestnum
7702 Template unnamed parameter
7704 {{paramtestnum|Main Page|the main page}}
7706 <p><a href="/wiki/Main_Page" title="Main Page">the main page</a>
7711 Template:templatesimple
7717 Template:templateredirect
7719 #redirect [[Template:templatesimple]]
7723 Template:templateasargtestnum
7729 Template:templateasargtest
7731 {{template{{{templ}}}}}
7735 Template:templateasargtest2
7741 Template with template name as unnamed argument
7743 {{templateasargtestnum|templatesimple}}
7750 Template with template name as argument
7752 {{templateasargtest|templ=simple}}
7759 Template with template name as argument (2)
7761 {{templateasargtest2|templ=templatesimple}}
7768 Template:templateasargtestdefault
7770 {{{{{templ|templatesimple}}}}}
7780 Template with default value
7782 {{templateasargtestdefault}}
7789 Template with default value (value set)
7791 {{templateasargtestdefault|templ=templa}}
7800 {{templateredirect}}
7807 Template with argument in separate line
7809 {{ templateasargtest |
7817 Template with complex template as argument
7820 param ={{ templateasargtest |
7823 <p>This is a test template with parameter (test)
7828 Template with thumb image (with link in description)
7831 param =[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]}}
7833 This is a test template with parameter <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=Special:Upload&wpDestFile=Noimage.png" class="new" title="File:Noimage.png">File:Noimage.png</a> <div class="thumbcaption"><a href="/index.php?title=No_link&action=edit&redlink=1" class="new" title="No link (page does not exist)">link</a> <a href="/index.php?title=No_link&action=edit&redlink=1" class="new" title="No link (page does not exist)">caption</a></div></div></div>
7838 Template:complextemplate
7840 {{{1}}} {{paramtest|
7841 param ={{{param}}}}}
7845 Template with complex arguments
7848 param ={{ templateasargtest |
7849 templ = simple }}|[[Template:complextemplate|link]]}}
7851 <p><a href="/wiki/Template:Complextemplate" title="Template:Complextemplate">link</a> This is a test template with parameter (test)
7856 BUG 553: link with two variables in a piped link
7859 |[[{{{1}}}|{{{2}}}]]
7864 <td>[[{{{1}}}|{{{2}}}]]
7870 Magic variable as template parameter
7872 {{paramtest|param={{SITENAME}}}}
7874 <p>This is a test template with parameter MediaWiki
7881 [[{{{param}}}|link]]
7885 Template parameter as link source
7887 {{linktest|param=Main Page}}
7889 <p><a href="/wiki/Main_Page" title="Main Page">link</a>
7894 Template-generated attribute string (k='v')
7896 <span {{attr_str|id|v1}}>bar</span>
7898 <p><span id="v1">bar</span>
7905 including another template, {{paramtest|param={{{arg}}}}}
7909 Template passing argument to another template
7911 {{paramtest2|arg='hmm'}}
7913 <p>including another template, This is a test template with parameter 'hmm'
7924 Template as link source
7928 [[{{linktest2}}|Main Page]]
7930 [[{{linktest2}}]]Page
7932 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
7933 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
7934 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>Page
7952 Template infinite loop
7956 <p><span class="error">Template loop detected: <a href="/wiki/Template:Loop1" title="Template:Loop1">Template:Loop1</a></span>
7961 Template from main namespace
7980 BUG 529: Template with table, not included at beginning of line
7999 BUG 523: Template shouldn't eat newline (or add an extra one before table)
8019 BUG 41: Template parameters shown as broken links
8028 Template with targets containing wikilinks
8032 {{[[{{echo|foo}}]]}}
8034 {{{{echo|[[foo}}]]}}
8036 <p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
8037 </p><p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
8045 ''None'' of '''this''' should be
8047 but rather passed unmodified
8051 # hmm, fix this or just deprecate msgnw and document its behavior?
8057 {{msgnw:MSGNW test}}
8059 <p>''None'' of '''this''' should be
8061 but rather passed unmodified
8069 {{int:youhavenewmessages|lots of money|not!}}
8071 <p>You have lots of money (not!).
8078 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
8082 <includeonly> and <noinclude> being included
8093 <onlyinclude>Foo</onlyinclude>bar
8097 <onlyinclude> being included
8109 <onlyinclude>Foo</onlyinclude>bar<includeonly>zar</includeonly>
8113 <onlyinclude> and <includeonly> being included
8122 <includeonly> and <noinclude> on a page
8124 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
8131 Un-closed <noinclude>
8138 <onlyinclude> on a page
8140 <onlyinclude>Foo</onlyinclude>bar
8147 Un-closed <onlyinclude>
8154 Self-closed noinclude, includeonly, onlyinclude tags
8165 Unbalanced includeonly and noinclude tags
8169 |b</noinclude></noinclude>
8170 |c</noinclude></includeonly>
8171 |d</includeonly></includeonly>
8180 <td>c</includeonly>
8182 <td>d</includeonly></includeonly>
8188 Template:Includeonly section
8191 ==Includeonly section==
8197 Bug 6563: Edit link generation for section shown by <includeonly>
8199 {{includeonly section}}
8201 <h2><span class="mw-headline" id="Includeonly_section">Includeonly section</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Template:Includeonly_section&action=edit&section=T-1" title="Template:Includeonly section">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
8202 <h2><span class="mw-headline" id="Section_T-1">Section T-1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Template:Includeonly_section&action=edit&section=T-2" title="Template:Includeonly section">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
8206 # Uses same input as the contents of [[Template:Includeonly section]]
8208 Bug 6563: Section extraction for section shown by <includeonly>
8213 ==Includeonly section==
8221 Bug 6563: Edit link generation for section suppressed by <includeonly>
8224 ==Includeonly section==
8228 <h2><span class="mw-headline" id="Section_1">Section 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
8233 Bug 6563: Section extraction for section suppressed by <includeonly>
8238 ==Includeonly section==
8246 Un-closed <includeonly>
8252 # TODO: test with DOM fragment reuse!
8254 Parsoid: DOM fragment reuse
8256 parsoid=wt2wt,wt2html
8258 a{{echo|b<table></table>c}}d
8270 a<span about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b
8271 <table></table>c"}},"i":0}}]}'>b</span>
8272 <table about="#mwt1"></table><span about="#mwt1">c</span>d
8275 <p about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":["a",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"b\n<table></table>\nc"}},"i":0}},"d"]}'>ab</p><span about="#mwt2">
8277 <table about="#mwt2"></table><span about="#mwt2">
8279 <p about="#mwt2">cd</p>
8282 <p about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\n\n<table></table>\n\nb"}},"i":0}}]}'>a</p><span about="#mwt3">
8285 <table about="#mwt3"></table><span about="#mwt3">
8288 <p about="#mwt3">b</p>
8292 Parsoid: Merge double tds (bug 50603)
8301 <tr><td about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":["|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"{{!}} foo"}},"i":0}}]}'> foo</td></tr>
8306 Parsoid: Merge double tds in nested transclusion content (bug 50603)
8316 <div about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<div>"}},"i":0}},"\n{|\n|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"{{!}} foo"}},"i":1}},"\n|}\n",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"</div>"}},"i":2}}]}'>
8318 <tr><td data-mw='{"parts":["|"]}'> foo</td></tr>
8324 ### <includeonly> and <noinclude> in attributes
8327 0. includeonly around the entire attribute
8329 <span <includeonly>id="v1"</includeonly><noinclude>id="v2"</noinclude>>bar</span>
8331 <p><span id="v2">bar</span>
8336 1. includeonly in html attr key
8338 <span <noinclude>id</noinclude><includeonly>about</includeonly>="foo">bar</span>
8340 <p><span id="foo">bar</span>
8345 2. includeonly in html attr value
8347 <span id="<noinclude>v1</noinclude><includeonly>v2</includeonly>">bar</span>
8348 <span id=<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>>bar</span>
8350 <p><span id="v1">bar</span>
8351 <span id="v1">bar</span>
8356 3. includeonly in part of an attr value
8358 <span style="color:<noinclude>red</noinclude><includeonly>blue</includeonly>;">bar</span>
8360 <p><span style="color:red;">bar</span>
8365 4. includeonly in table attributes
8389 ### Testing parsing of templates where a template arg
8390 ### has the same name as the template itself.
8400 Templates: Template Name/Arg clash: 1. Use of positional param
8409 Templates: Template Name/Arg clash: 2. Use of named param
8418 Templates: Template Name/Arg clash: 3. Use of named param with empty input
8427 ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged
8431 Templates: 1. Simple use
8440 Templates: 2. Inside a block tag
8442 <div>{{echo|Foo}}</div>
8443 <blockquote>{{echo|Foo}}</blockquote>
8446 <blockquote>Foo</blockquote>
8451 Templates: P-wrapping: 1a. Templates on consecutive lines
8462 Templates: P-wrapping: 1b. Templates on consecutive lines
8476 Templates: P-wrapping: 1c. Templates on consecutive lines
8479 {{echo|bar}} <div>baz</div>
8488 Templates: P-wrapping: 1d. Template preceded by comment-only line
8497 <p about="#mwt223" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"Bar"}},"i":0}}]}'>Bar</p>
8501 Templates: Inline Text: 1. Multiple template uses
8503 {{echo|Foo}}bar{{echo|baz}}
8510 Templates: Inline Text: 2. Back-to-back template uses
8512 {{echo|Foo}}{{echo|bar}}
8519 Templates: Block Tags: 1. Multiple template uses
8521 {{echo|<div>Foo</div>}}<div>bar</div>{{echo|<div>baz</div>}}
8523 <div>Foo</div><div>bar</div><div>baz</div>
8528 Templates: Block Tags: 2. Back-to-back template uses
8530 {{echo|<div>Foo</div>}}{{echo|<div>bar</div>}}
8532 <div>Foo</div><div>bar</div>
8537 Templates: Links: 1. Simple example
8539 {{echo|[[Foo|bar]]}}
8541 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
8546 Templates: Links: 2. Generation of link href
8548 [[{{echo|Foo}}|bar]]
8550 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
8555 Templates: Links: 3. Generation of part of a link href
8557 [[Fo{{echo|o}}|bar]]
8561 [[Foo{{echo|bar}}baz]]
8563 [[Foo{{echo|bar}}|bar]]
8565 [[:Foo{{echo|bar}}]]
8567 [[:Foo{{echo|bar}}|bar]]
8569 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
8570 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
8571 </p><p><a href="/index.php?title=Foobarbaz&action=edit&redlink=1" class="new" title="Foobarbaz (page does not exist)">Foobarbaz</a>
8572 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
8573 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
8574 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
8579 Templates: Links: 4. Multiple templates generating link href
8581 [[{{echo|F}}{{echo|o}}ob{{echo|ar}}]]
8583 <p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
8588 Templates: Links: 5. Generation of link text
8590 [[Foo|{{echo|bar}}]]
8592 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
8597 Templates: Links: 5. Nested templates (only outermost template should be marked)
8599 {{echo|[[{{echo|Foo}}|bar]]}}
8601 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
8606 Templates: HTML Tag: 1. Generation of HTML attr. key
8608 <div {{echo|style}}="color:red;">foo</div>
8610 <div style="color:red;">foo</div>
8615 Templates: HTML Tag: 2. Generation of HTML attr. value
8617 <div style={{echo|'color:red;'}}>foo</div>
8619 <div style="color:red;">foo</div>
8624 Templates: HTML Tag: 3. Generation of HTML attr key and value
8626 <div {{echo|style}}={{echo|'color:red;'}}>foo</div>
8628 <div style="color:red;">foo</div>
8633 Templates: HTML Tag: 4. Generation of starting piece of HTML attr value
8635 <div title="{{echo|This is a long title}} with just one piece templated">foo</div>
8637 <div title="This is a long title with just one piece templated">foo</div>
8642 Templates: HTML Tag: 5. Generation of middle piece of HTML attr value
8644 <div title="This is a long title with just {{echo|one piece}} templated">foo</div>
8646 <div title="This is a long title with just one piece templated">foo</div>
8651 Templates: HTML Tag: 6. Generation of end piece of HTML attr value
8653 <div title="This is a long title with just one piece {{echo|templated}}">foo</div>
8655 <div title="This is a long title with just one piece templated">foo</div>
8660 Templates: HTML Tag: 7. Generation of partial attribute key string
8662 <div st{{echo|yle}}="color:red;">foo</div>
8664 <div style="color:red;">foo</div>
8669 Templates: HTML Tables: 1. Generating start of a HTML table
8671 {{echo|<table><tr><td>foo</td>}}</tr></table>
8673 <table><tr><td>foo</td></tr></table>
8678 Templates: HTML Tables: 2a. Generating middle of a HTML table
8680 <table><tr>{{echo|<td>foo</td>}}</tr></table>
8682 <table><tr><td>foo</td></tr></table>
8687 Templates: HTML Tables: 2b. Generating middle of a HTML table
8689 <table>{{echo|<tr><td>foo</td></tr>}}</table>
8691 <table><tr><td>foo</td></tr></table>
8696 Templates: HTML Tables: 3. Generating end of a HTML table
8698 <table><tr>{{echo|<td>foo</td></tr></table>}}
8700 <table><tr><td>foo</td></tr></table>
8705 Templates: HTML Tables: 4a. Generating a single tag of a HTML table
8707 {{echo|<table>}}<tr><td>foo</td></tr></table>
8709 <table><tr><td>foo</td></tr></table>
8714 Templates: HTML Tables: 4b. Generating a single tag of a HTML table
8716 <table>{{echo|<tr>}}<td>foo</td></tr></table>
8718 <table><tr><td>foo</td></tr></table>
8723 Templates: HTML Tables: 4c. Generating a single tag of a HTML table
8725 <table><tr>{{echo|<td>}}foo</td></tr></table>
8727 <table><tr><td>foo</td></tr></table>
8732 Templates: HTML Tables: 4d. Generating a single tag of a HTML table
8734 <table><tr><td>foo{{echo|</td>}}</tr></table>
8736 <table><tr><td>foo</td></tr></table>
8741 Templates: HTML Tables: 4e. Generating a single tag of a HTML table
8743 <table><tr><td>foo</td>{{echo|</tr>}}</table>
8745 <table><tr><td>foo</td></tr></table>
8750 Templates: HTML Tables: 4f. Generating a single tag of a HTML table
8752 <table><tr><td>foo</td></tr>{{echo|</table>}}
8754 <table><tr><td>foo</td></tr></table>
8759 Templates: HTML Tables: 5. Proper fostering of categories from inside
8761 parsoid=wt2html,wt2wt
8763 <table>[[Category:foo1]]<tr><td>foo</td></tr></table>
8764 <!--Two categories (Bug 50330)-->
8765 <table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>
8767 <link rel="mw:PageProp/Category" href="./Category:Foo1"><table><tbody><tr><td>foo</td></tr></tbody></table>
8768 <!--Two categories (Bug 50330)-->
8769 <link rel="mw:PageProp/Category" href="./Category:Bar1"><link rel="mw:PageProp/Category" href="./Category:Bar2"><table><tbody><tr><td>foo</td></tr></tbody></table>
8773 Templates: Wiki Tables: 1a. Fostering of entire template content
8781 <tr><td></td></tr></table>
8786 Templates: Wiki Tables: 1b. Fostering of entire template content
8799 <tr><td></td></tr></table>
8804 Templates: Wiki Tables: 2. Fostering of partial template content
8814 <tr><td></td></tr></table>
8819 Templates: Wiki Tables: 3. td-content via multiple templates
8822 {{echo|{{pipe}}a}}{{echo|b}}
8833 Templates: Wiki Tables: 4. Templated tags, no content
8839 <tr><td></td></tr></table>
8844 Templates: Wiki Tables: 5. Templated tags, regular td-tags
8858 Templates: Wiki Tables: 6. Templated tags, templated td-tags
8872 Templates: Lists: Multi-line list-items via templates
8874 *{{echo|a {{nonexistent|
8876 *{{echo|b {{nonexistent|
8879 <ul><li>a <a href="/index.php?title=Template:Nonexistent&action=edit&redlink=1" class="new" title="Template:Nonexistent (page does not exist)">Template:Nonexistent</a></li>
8880 <li>b <a href="/index.php?title=Template:Nonexistent&action=edit&redlink=1" class="new" title="Template:Nonexistent (page does not exist)">Template:Nonexistent</a></li></ul>
8885 Templates: Ugly nesting: 1. Quotes opened/closed across templates (echo)
8887 {{echo|''a}}{{echo|b''c''d}}{{echo|''e}}
8889 <p><i>ab</i>c<i>d</i>e
8894 Templates: Ugly nesting: 2. Quotes opened/closed across templates (echo_with_span)
8895 (PHP parser generates misnested html)
8897 {{echo_with_span|''a}}{{echo_with_span|b''c''d}}{{echo_with_span|''e}}
8899 <p><span about="#mwt1" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo_with_span","href":"./Template:Echo_with_span"},"params":{"1":{"wt":"''a"}},"i":0}}]}"><i>a</i></span><i about="#mwt2" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo_with_span","href":"./Template:Echo_with_span"},"params":{"1":{"wt":"b''c''d"}},"i":0}},{"template":{"target":{"wt":"echo_with_span","href":"./Template:Echo_with_span"},"params":{"1":{"wt":"''e"}},"i":1}}]}"><span>b</span></i><span about="#mwt2">c</span><i about="#mwt2">d<span></span></i><span about="#mwt2">e</span></p>
8903 Templates: Ugly nesting: 3. Quotes opened/closed across templates (echo_with_div)
8904 (PHP parser generates misnested html; Parsoid html2wt mode adds newlines between {{echo}}s)
8906 parsoid=wt2html,wt2wt
8908 {{echo_with_div|''a}}{{echo_with_div|b''c''d}}{{echo_with_div|''e}}
8910 <div about="#mwt1" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo_with_div","href":"./Template:Echo_with_div"},"params":{"1":{"wt":"''a"}},"i":0}}]}"><i>a</i></div>
8911 <div about="#mwt2" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo_with_div","href":"./Template:Echo_with_div"},"params":{"1":{"wt":"b''c''d"}},"i":0}}]}"><i>b</i>c<i>d</i></div>
8912 <div about="#mwt3" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo_with_div","href":"./Template:Echo_with_div"},"params":{"1":{"wt":"''e"}},"i":0}}]}">e</div>
8916 Templates: Ugly nesting: 4. Divs opened/closed across templates
8918 a<div>b{{echo|c</div>d}}e
8925 Templates: Ugly templates: 1. Navbox template parses badly leading to table misnesting
8931 |{{echo|foo</table>}}
8935 <table about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":["{|\n|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</table>"}},"i":0}},"\n|bar\n|}"]}'>
8939 <td>foo</td></tr></tbody></table><span about="#mwt1">
8940 </span><span about="#mwt1">|bar</span><span about="#mwt1">
8945 Templates: Ugly templates: 2. Navbox template parses badly leading to table misnesting
8955 <td>1. {{echo|foo </table>}}</td>
8957 <td>2. {{echo|baz </table>}}</td>
8970 <table about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":["<table>\n <tr>\n <td>\n <table>\n <tr>\n <td>1. ",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo </table>"}},"i":0}},"</td>\n <td> bar </td>\n <td>2. ",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"baz </table>"}},"i":1}},"</td>\n </tr>\n <tr>\n <td>abc</td>\n </tr>\n </table>\n </td>\n </tr>\n <tr>\n <td>xyz</td>\n </tr>\n</table>"]}'>
8975 <td>1. foo </td></tr></tbody></table></td>
8977 <td>2. baz </td></tr></tbody></table><span about="#mwt2">
8978 </span><span about="#mwt2">
8979 </span><span about="#mwt2">
8980 </span><span about="#mwt2">abc</span><span about="#mwt2">
8981 </span><span about="#mwt2">
8982 </span><span about="#mwt2">
8983 </span><span about="#mwt2">
8984 </span><span about="#mwt2">
8985 </span><span about="#mwt2">
8986 </span><span about="#mwt2">xyz</span><span about="#mwt2">
8987 </span><span about="#mwt2">
8992 Templates: Ugly templates: 3. newline-only template parameter
9001 # This looks like a bug: a single newline triggers p/br for some reason.
9003 Templates: Ugly templates: 4. newline-only template parameter inconsistency
9012 # Bug 64017 -- ugly wikitext with fostered content generates two template ranges that
9013 # have a true overlap (T1-start - T2-start - T1-end - T2-end).
9015 Templates: Ugly templates: 5. Template encapsulation test: Non-trivial overlap of template ranges is properly handled
9021 <div about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<table>"}},"i":0}},"\n",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<div>foo"}},"i":1}},"\n",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"</table>"}},"i":2}}]}' data-parsoid='{"stx":"html","autoInsertedEnd":true,"pi":[[{"k":"1","spc":["","","",""]}],[{"k":"1","spc":["","","",""]}],[{"k":"1","spc":["","","",""]}]]}'>foo
9022 </div><table about="#mwt1" data-parsoid='{"stx":"html"}'>
9026 # Bug 64017 -- ugly wikitext with fostered content generates two template ranges
9027 # that are "identical" and generate nesting cycles in the algorithm
9029 Templates: Ugly templates: 6. Template encapsulation test: Cyclical nesting of template ranges is properly handled
9031 {{echo|<table><tr><td><table>}}
9035 <table about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<table><tr><td><table>"}},"i":0}},"\n",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<div>"}},"i":1}},"\n",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"</div>"}},"i":2}}]}' data-parsoid='{"stx":"html","autoInsertedEnd":true,"pi":[[{"k":"1","spc":["","","",""]}],[{"k":"1","spc":["","","",""]}],[{"k":"1","spc":["","","",""]}]]}'><tbody><tr data-parsoid='{"stx":"html"}'><td data-parsoid='{"stx":"html"}'><div data-parsoid='{"stx":"html"}'>
9036 </div><table about="#mwt1" data-parsoid='{"stx":"html"}'>
9037 </table></td></tr></tbody></table>
9041 Parser Functions: 1. Simple example
9050 Parser Functions: 2. Nested use (only outermost should be marked up)
9059 ### Pre-save transform tests
9062 pre-save transform: subst:
9068 This is a test template
9072 pre-save transform: normal template
9082 pre-save transform: nonexistent template
9086 {{thistemplatedoesnotexist}}
9088 {{thistemplatedoesnotexist}}
9093 pre-save transform: subst magic variables
9102 # This is bug 89, which I fixed. -- wtm
9104 pre-save transform: subst: templates with parameters
9108 {{subst:paramtest|param="something else"}}
9110 This is a test template with parameter "something else"
9116 <nowiki>'''not wiki'''</nowiki>
9120 pre-save transform: nowiki in subst (bug 1188)
9124 {{subst:nowikitest}}
9126 <nowiki>'''not wiki'''</nowiki>
9131 Template:commenttest
9133 This template has <!-- a comment --> in it.
9137 pre-save transform: comment in subst (bug 1936)
9141 {{subst:commenttest}}
9143 This template has <!-- a comment --> in it.
9147 pre-save transform: unclosed tag
9151 <nowiki>'''not wiki'''
9153 <nowiki>'''not wiki'''
9157 pre-save transform: mixed tag case
9161 <NOwiki>'''not wiki'''</noWIKI>
9163 <NOwiki>'''not wiki'''</noWIKI>
9167 pre-save transform: unclosed comment in <nowiki>
9171 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
9173 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
9176 # Leading @ in this template definition works around a limitation
9177 # in parsoid's parserTests which otherwise strips the <span> from the
9178 # result (confusing it for a template wrapper)
9182 @<span onmouseover="alert('crap')">Oh no</span>
9186 (confirming safety of fix for subst bug 1936)
9188 {{Template:dangerous}}
9190 <p>@<span>Oh no</span>
9195 pre-save transform: comment containing gallery (bug 5024)
9199 <!-- <gallery>data</gallery> -->
9201 <!-- <gallery>data</gallery> -->
9205 pre-save transform: comment containing extension
9209 <!-- <tag>data</tag> -->
9211 <!-- <tag>data</tag> -->
9215 pre-save transform: comment containing nowiki
9219 <!-- <nowiki>data</nowiki> -->
9221 <!-- <nowiki>data</nowiki> -->
9225 pre-save transform: <noinclude> in subst (bug 3298)
9235 pre-save transform: <onlyinclude> in subst (bug 3298)
9247 {{<includeonly>subst:</includeonly>Includes}}
9251 Template:SafeSubstTest
9253 {{<includeonly>safesubst:</includeonly>Includes}}
9257 bug 22297: safesubst: works during PST
9261 {{subst:SafeSubstTest}}{{safesubst:SubstTest}}
9267 bug 22297: safesubst: works during normal parse
9276 subst: does not work during normal parse
9280 <p>{{subst:Includes}}
9285 pre-save transform: context links ("pipe trick")
9289 [[Article (context)|]]
9292 [[Bar:Article (context)|]]
9293 [[:Bar:Article (context)|]]
9295 [[|Article (context)]]
9299 [[Article (context)|Article]]
9300 [[Bar:Article|Article]]
9301 [[:Bar:Article|Article]]
9302 [[Bar:Article (context)|Article]]
9303 [[:Bar:Article (context)|Article]]
9305 [[Article (context)]]
9306 [[Bar:X (Y) Z|X (Y) Z]]
9307 [[:Bar:X (Y) Z|X (Y) Z]]
9311 pre-save transform: context links ("pipe trick") with interwiki prefix
9315 [[interwiki:Article|]]
9316 [[:interwiki:Article|]]
9317 [[interwiki:Bar:Article|]]
9318 [[:interwiki:Bar:Article|]]
9320 [[interwiki:Article|Article]]
9321 [[:interwiki:Article|Article]]
9322 [[interwiki:Bar:Article|Bar:Article]]
9323 [[:interwiki:Bar:Article|Bar:Article]]
9327 pre-save transform: context links ("pipe trick") with parens in title
9329 pst title=[[Somearticle (context)]]
9333 [[Article (context)|Article]]
9337 pre-save transform: context links ("pipe trick") with comma in title
9339 pst title=[[Someplace, Somewhere]]
9342 [[Otherplace, Elsewhere|]]
9343 [[Otherplace, Elsewhere, Anywhere|]]
9345 [[Otherplace, Somewhere|Otherplace]]
9346 [[Otherplace, Elsewhere|Otherplace]]
9347 [[Otherplace, Elsewhere, Anywhere|Otherplace]]
9351 pre-save transform: context links ("pipe trick") with parens and comma
9353 pst title=[[Someplace (IGNORED), Somewhere]]
9356 [[Otherplace (place), Elsewhere|]]
9358 [[Otherplace, Somewhere|Otherplace]]
9359 [[Otherplace (place), Elsewhere|Otherplace]]
9363 pre-save transform: context links ("pipe trick") with comma and parens
9365 pst title=[[Who, me? (context)]]
9368 [[Me, Myself, and I (1937 song)|]]
9370 [[Yes, you. (context)|Yes, you.]]
9371 [[Me, Myself, and I (1937 song)|Me, Myself, and I]]
9375 pre-save transform: context links ("pipe trick") with namespace
9377 pst title=[[Ns:Somearticle]]
9381 [[Ns:Article|Article]]
9385 pre-save transform: context links ("pipe trick") with namespace and parens
9387 pst title=[[Ns:Somearticle (context)]]
9391 [[Ns:Article (context)|Article]]
9395 pre-save transform: context links ("pipe trick") with namespace and comma
9397 pst title=[[Ns:Somearticle, Context, Whatever]]
9401 [[Ns:Article, Context, Whatever|Article]]
9405 pre-save transform: context links ("pipe trick") with namespace, comma and parens
9407 pst title=[[Ns:Somearticle, Context (context)]]
9411 [[Ns:Article (context)|Article]]
9415 pre-save transform: context links ("pipe trick") with namespace, parens and comma
9417 pst title=[[Ns:Somearticle (IGNORED), Context]]
9421 [[Ns:Article, Context|Article]]
9425 pre-save transform: context links ("pipe trick") with full-width parens and no space (Japanese and Chinese style, bug 30149)
9429 [[Article(context)|]]
9430 [[Bar:Article(context)|]]
9431 [[:Bar:Article(context)|]]
9432 [[|Article(context)]]
9436 [[Article(context)|Article]]
9437 [[Bar:Article(context)|Article]]
9438 [[:Bar:Article(context)|Article]]
9439 [[Article(context)]]
9441 [[:Bar:X(Y)Z|X(Y)Z]]
9445 pre-save transform: context links ("pipe trick") with full-width parens and space (Japanese and Chinese style, bug 30149)
9449 [[Article (context)|]]
9450 [[Bar:Article (context)|]]
9451 [[:Bar:Article (context)|]]
9452 [[|Article (context)]]
9456 [[Article (context)|Article]]
9457 [[Bar:Article (context)|Article]]
9458 [[:Bar:Article (context)|Article]]
9459 [[Article (context)]]
9460 [[Bar:X (Y) Z|X (Y) Z]]
9461 [[:Bar:X (Y) Z|X (Y) Z]]
9465 pre-save transform: context links ("pipe trick") with parens and no space (Korean style, bug 30149)
9469 [[Article(context)|]]
9470 [[Bar:Article(context)|]]
9471 [[:Bar:Article(context)|]]
9472 [[|Article(context)]]
9476 [[Article(context)|Article]]
9477 [[Bar:Article(context)|Article]]
9478 [[:Bar:Article(context)|Article]]
9479 [[Article(context)]]
9481 [[:Bar:X(Y)Z|X(Y)Z]]
9485 pre-save transform: context links ("pipe trick") with commas (bug 21660)
9489 [[Article (context), context|]]
9490 [[Article (context),context|]]
9491 [[Bar:Article (context), context|]]
9492 [[Bar:Article (context),context|]]
9493 [[:Bar:Article (context), context|]]
9494 [[:Bar:Article (context),context|]]
9496 [[Article (context), context|Article]]
9497 [[Article (context),context|Article]]
9498 [[Bar:Article (context), context|Article]]
9499 [[Bar:Article (context),context|Article]]
9500 [[:Bar:Article (context), context|Article]]
9501 [[:Bar:Article (context),context|Article]]
9505 pre-save transform: trim trailing empty lines
9509 Empty lines are trimmed
9515 Empty lines are trimmed
9519 pre-save transform: Signature expansion
9524 * <noinclude>~~~</noinclude>
9525 * <includeonly>~~~</includeonly>
9526 * <onlyinclude>~~~</onlyinclude>
9528 * [[Special:Contributions/127.0.0.1|127.0.0.1]]
9529 * <noinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</noinclude>
9530 * <includeonly>[[Special:Contributions/127.0.0.1|127.0.0.1]]</includeonly>
9531 * <onlyinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</onlyinclude>
9536 pre-save transform: Signature expansion in nowiki tags (bug 93)
9542 <nowiki>~~~~</nowiki>
9544 <includeonly><nowiki>~~~~</nowiki></includeonly>
9546 <noinclude><nowiki>~~~~</nowiki></noinclude>
9548 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
9550 {{subst:Foo}} shall be converted to FOO
9552 As well as inside noinclude/onlyinclude
9553 <noinclude>{{subst:Foo}}</noinclude>
9554 <onlyinclude>{{subst:Foo}}</onlyinclude>
9556 But not inside includeonly
9557 <includeonly>{{subst:Foo}}</includeonly>
9561 <nowiki>~~~~</nowiki>
9563 <includeonly><nowiki>~~~~</nowiki></includeonly>
9565 <noinclude><nowiki>~~~~</nowiki></noinclude>
9567 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
9569 FOO shall be converted to FOO
9571 As well as inside noinclude/onlyinclude
9572 <noinclude>FOO</noinclude>
9573 <onlyinclude>FOO</onlyinclude>
9575 But not inside includeonly
9576 <includeonly>{{subst:Foo}}</includeonly>
9580 Parsoid: Recognize nowiki with trailing space in tags
9584 <nowiki ><div>[[foo]]</nowiki >
9592 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
9599 Parsoid: Recognize nowiki with odd capitalization
9603 <noWikI ><div>[[foo]]</Nowiki >
9605 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
9610 Parsoid: Escape nowiki with trailing space in tags
9614 <nowiki > foo </nowiki >
9620 <p><nowiki > foo </nowiki ></p>
9621 <p>a<nowiki />b</p>
9622 <p>c<nowiki/ >d</p>
9626 Parsoid: Escape weird noWikI capitalizations
9630 <noWikI > foo </NoWikI >
9632 <p><noWikI > foo </NoWikI ></p>
9636 ### Message transform tests
9639 message transform: magic variables
9649 message transform: should not transform wiki markup
9659 message transform: <noinclude> in transcluded template (bug 4926)
9669 message transform: <onlyinclude> in transcluded template (bug 4926)
9679 {{#special:}} page name, known
9683 {{#special:Recentchanges}}
9685 Special:RecentChanges
9689 {{#special:}} page name with subpage, known
9693 {{#special:Recentchanges/param}}
9695 Special:RecentChanges/param
9699 {{#special:}} page name, unknown
9703 {{#special:foobar nonexistent}}
9705 Special:Foobar nonexistent
9709 {{#speciale:}} page name, known
9713 {{#speciale:Recentchanges}}
9715 Special:RecentChanges
9719 {{#speciale:}} page name with subpage, known
9723 {{#speciale:Recentchanges/param}}
9725 Special:RecentChanges/param
9729 {{#speciale:}} page name, unknown
9733 {{#speciale:foobar nonexistent}}
9735 Special:Foobar_nonexistent
9741 ### For Parsoid-specific tests, see
9742 #### https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
9747 parsoid=wt2html,wt2wt,html2html
9749 [[Image:foobar.jpg]]
9751 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
9754 <p><span class="mw-default-size" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span>
9759 Simple image (using File: namespace, now canonical)
9763 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
9766 <p><span class="mw-default-size" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span>
9773 [[File:Foobar.jpg|right]]
9775 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
9778 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></figure>
9784 [[File:Foobar.jpg|right|Caption text]]
9786 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption text"><img alt="Caption text" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
9789 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption text</figcaption></figure>
9793 Image with caption, bug 53312 #1
9795 [[File:Foobar.jpg|right|Caption page stuff]]
9797 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption page stuff"><img alt="Caption page stuff" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
9800 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption page stuff</figcaption></figure>
9804 Image with caption, bug 53312 #2
9806 [[File:Foobar.jpg|right|Caption page=]]
9808 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption page="><img alt="Caption page=" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
9811 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption page=</figcaption></figure>
9815 Image with caption, bug 53312 #3
9817 [[File:Foobar.jpg|right|Caption page=stuff]]
9819 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption page=stuff"><img alt="Caption page=stuff" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
9822 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption page=stuff</figcaption></figure>
9826 Allow empty links in image captions (Bug 60753)
9830 [[File:Foobar.jpg|thumb|Caption [[Link1]]
9835 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Caption <a href="/index.php?title=Link1&action=edit&redlink=1" class="new" title="Link1 (page does not exist)">Link1</a> [[]] <a href="/index.php?title=Link2&action=edit&redlink=1" class="new" title="Link2 (page does not exist)">Link2</a></div></div></div>
9838 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"caption","ak":"Caption [[Link1]]\n[[]]\n[[Link2]]\n"}],"dsr":[0,59,2,2]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"dsr":[2,null,null,null]}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" height="25" width="220" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"25","width":"220"},"sa":{"resource":"File:Foobar.jpg"}}'/></a><figcaption data-parsoid='{"dsr":[null,57,null,null]}'>Caption <a rel="mw:WikiLink" href="./Link1" data-parsoid='{"stx":"simple","a":{"href":"./Link1"},"sa":{"href":"Link1"},"dsr":[32,41,2,2]}'>Link1</a>
9840 <a rel="mw:WikiLink" href="./Link2" data-parsoid='{"stx":"simple","a":{"href":"./Link2"},"sa":{"href":"Link2"},"dsr":[47,56,2,2]}'>Link2</a>
9841 </figcaption></figure>
9845 Link with empty target
9854 Image with empty attribute
9856 parsoid=wt2html,wt2wt,html2html
9858 [[File:Foobar.jpg|right||Caption text]]
9860 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption text"><img alt="Caption text" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
9863 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption text</figcaption></figure>
9867 1. Block image with individual attributes from templates
9869 [[File:Foobar.jpg|thumb|{{echo|137px}}|This is a caption]]
9871 <div class="thumb tright"><div class="thumbinner" style="width:139px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" width="137" height="16" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/206px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/274px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/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 caption</div></div></div>
9874 <figure typeof="mw:Image/Thumb mw:ExpandedAttrs" data-mw='{"attribs":[["thumbnail",{"html":"thumb"}],["width",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;137px&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;dsr&quot;:[24,38,null,null],&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]]}\">137px</span>"}]]}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="16" width="137"/></a><figcaption>This is a caption</figcaption></figure>
9878 2. Block Image with individual attributes from templates
9880 [[File:Foobar.jpg|{{echo|thumb}}|{{echo|137px}}|This is a caption]]
9882 <div class="thumb tright"><div class="thumbinner" style="width:139px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/137px-Foobar.jpg" width="137" height="16" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/206px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/274px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/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 caption</div></div></div>
9885 <figure typeof="mw:Image/Thumb mw:ExpandedAttrs" data-mw='{"attribs":[["thumbnail",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;thumb&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;dsr&quot;:[18,32,null,null],&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]]}\">thumb</span>"}],["width",{"html":"<span about=\"#mwt2\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;137px&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;dsr&quot;:[33,47,null,null],&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]]}\">137px</span>"}]]}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="16" width="137"/></a><figcaption>This is a caption</figcaption></figure>
9889 3. Inline image with individual attributes from templates
9891 [[File:Foobar.jpg|{{echo|50px}}]]
9893 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" width="50" height="6" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/75px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/100px-Foobar.jpg 2x" /></a>
9896 <p><span typeof="mw:Image mw:ExpandedAttrs" about="#mwt2" data-mw='{"attribs":[["width",{"html":"<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-mw=\"{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;50px&quot;}},&quot;i&quot;:0}}]}\" data-parsoid=\"{&quot;dsr&quot;:[18,31,null,null],&quot;pi&quot;:[[{&quot;k&quot;:&quot;1&quot;,&quot;spc&quot;:[&quot;&quot;,&quot;&quot;,&quot;&quot;,&quot;&quot;]}]]}\">50px</span>"}]]}' data-parsoid='{"optList":[{"ck":"width","ak":"{{echo|50px}}"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
9899 ## Parsoid does not provide editing support for images where templates produce multiple image attributes.
9900 ## To signal this, we add a 'mw:Placeholder' type to such images. This could change in the future.
9902 Image with multiple attributes from the same template
9904 [[File:Foobar.jpg|{{image_attribs}}]]
9906 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption text"><img alt="Caption text" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
9909 <figure class="mw-default-size mw-halign-right" typeof="mw:Image mw:Placeholder"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption text</figcaption></figure>
9913 Image with link tails
9917 123[[File:Foobar.jpg]]456
9918 123[[File:Foobar.jpg|right]]456
9919 123[[File:Foobar.jpg|thumb]]456
9921 <p>123<a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>456
9923 123<div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>456
9924 123<div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>456
9927 <p>123<span class="mw-default-size" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span>456</p>
9928 123<figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></figure>456
9929 123<figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" height="25" width="220"></a></figure>456
9933 Image with multiple captions -- only last one is accepted
9935 [[File:Foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
9937 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption3 - accepted"><img alt="Caption3 - accepted" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
9940 <figure class="mw-default-size mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a><figcaption>Caption3 - accepted</figcaption></figure>
9944 Image with multiple widths -- use last
9946 [[File:Foobar.jpg|200px|300px|caption]]
9948 <p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg" width="300" height="34" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/450px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/600px-Foobar.jpg 2x" /></a>
9951 <p><span typeof="mw:Image" data-mw='{"caption":"caption"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="34" width="300"/></a></span></p>
9955 Image with multiple alignments -- use first (bug 48664)
9959 [[File:Foobar.jpg|thumb|left|right|center|caption]]
9961 [[File:Foobar.jpg|middle|text-top|caption]]
9963 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
9964 <p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" style="vertical-align: middle" /></a>
9967 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
9968 <p><span class="mw-default-size mw-valign-middle" typeof="mw:Image" data-mw='{"caption":"caption"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
9972 Image with width attribute at different positions
9974 [[File:Foobar.jpg|200px|right|Caption]]
9975 [[File:Foobar.jpg|right|200px|Caption]]
9976 [[File:Foobar.jpg|right|Caption|200px]]
9978 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption"><img alt="Caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a></div>
9979 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption"><img alt="Caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a></div>
9980 <div class="floatright"><a href="/wiki/File:Foobar.jpg" class="image" title="Caption"><img alt="Caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" width="200" height="23" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a></div>
9983 <figure class="mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" height="23" width="200"></a><figcaption>Caption</figcaption></figure>
9984 <figure class="mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" height="23" width="200"></a><figcaption>Caption</figcaption></figure>
9985 <figure class="mw-halign-right" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" height="23" width="200"></a><figcaption>Caption</figcaption></figure>
9988 # a sad bit of backward-compatibility
9990 Image with size specified with pxpx (bug 13500, 51628)
9992 parsoid=wt2html,wt2wt,html2html
9994 [[File:Foobar.jpg|20pxpx]]
9995 [[File:Foobar.jpg|200x20pxpx]]
9997 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/20px-Foobar.jpg" width="20" height="2" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/30px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/40px-Foobar.jpg 2x" /></a>
9998 <a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/177px-Foobar.jpg" width="177" height="20" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/265px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/353px-Foobar.jpg 2x" /></a>
10001 <p><span typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="2" width="20"/></a></span><span typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="20" width="177"/></a></span></p>
10005 Image with link parameter, wiki target
10007 [[File:Foobar.jpg|link=Main Page]]
10009 <p><a href="/wiki/Main_Page" title="Main Page"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10012 <p><span class="mw-default-size" typeof="mw:Image"><a href="Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
10015 # parsoid bug 49293 (part 1)
10017 Image with link parameter, URL target
10019 [[File:Foobar.jpg|link=http://example.com/]]
10021 <p><a href="http://example.com/" rel="nofollow"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10024 <p><span class="mw-default-size" typeof="mw:Image"><a href="http://example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
10027 # parsoid bug 49293 (part 2)
10029 Image with link parameter, protocol-less URL target
10031 [[File:Foobar.jpg|link=//example.com/]]
10033 <p><a href="//example.com/" rel="nofollow"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10036 <p><span class="mw-default-size" typeof="mw:Image"><a href="//example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
10040 Image with link parameter, wgExternalLinkTarget
10042 [[Image:foobar.jpg|link=http://example.com/]]
10044 wgExternalLinkTarget='foobar'
10046 <p><a href="http://example.com/" target="foobar" rel="nofollow"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10051 Image with link parameter, wgNoFollowLinks set to false
10053 [[Image:foobar.jpg|link=http://example.com/]]
10055 wgNoFollowLinks=false
10057 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10062 Image with link parameter, wgNoFollowDomainExceptions
10064 [[Image:foobar.jpg|link=http://example.com/]]
10066 wgNoFollowDomainExceptions='example.com'
10068 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10073 Image with link parameter, wgExternalLinkTarget, unnamed parameter
10075 [[Image:foobar.jpg|link=http://example.com/|Title]]
10077 wgExternalLinkTarget='foobar'
10079 <p><a href="http://example.com/" title="Title" target="foobar" rel="nofollow"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10084 Image with empty link parameter
10086 [[File:Foobar.jpg|link=]]
10088 <p><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" />
10091 <p><span class="mw-default-size" typeof="mw:Image"><span><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></span></span></p>
10095 Image with link parameter (wiki target) and unnamed parameter
10097 [[File:Foobar.jpg|link=Main_Page|Title]]
10099 <p><a href="/wiki/Main_Page" title="Title"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10102 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"Title"}'><a href="Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
10106 Image with link parameter (URL target) and unnamed parameter
10108 [[File:Foobar.jpg|link=http://example.com/|Title]]
10110 <p><a href="http://example.com/" title="Title" rel="nofollow"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10113 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"Title"}'><a href="http://example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"></a></span></p>
10117 Thumbnail image with link parameter
10120 parsoid=wt2html,wt2wt,html2html
10122 [[File:Foobar.jpg|thumb|link=http://example.com/|Title]]
10124 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="http://example.com/"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10127 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="http://example.com/"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>Title</figcaption></figure>
10131 Manually-specified thumbnail image
10135 [[File:Foobar.jpg|thumb=Thumb.png|Title]]
10137 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/File:Foobar.jpg"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10140 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
10144 Manually-specified thumbnail image with explicit link to wiki page
10147 parsoid=wt2html,wt2wt,html2html
10149 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|Title]]
10151 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10154 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="Main_Page"><img resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
10158 Manually-specified thumbnail image with explicit link to url
10161 parsoid=wt2html,wt2wt,html2html
10163 [[File:Foobar.jpg|thumb=Thumb.png|link=http://example.com|Title]]
10165 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="http://example.com"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10168 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="http://example.com"><img resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
10172 Manually-specified thumbnail image with explicit no link
10175 parsoid=wt2html,wt2wt,html2html
10177 [[File:Foobar.jpg|thumb=Thumb.png|link=|Title]]
10179 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><img alt="" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10182 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><span><img resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></span><figcaption>Title</figcaption></figure>
10186 Manually-specified thumbnail image with explicit link and alt text
10189 parsoid=wt2html,wt2wt,html2html
10191 [[File:Foobar.jpg|thumb=Thumb.png|link=Main_Page|alt=alttext|Title]]
10193 <div class="thumb tright"><div class="thumbinner" style="width:137px;"><a href="/wiki/Main_Page" title="Main Page"><img alt="alttext" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>Title</div></div></div>
10196 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-mw='{"thumb":"Thumb.png"}'><a href="Main_Page"><img alt="alttext" resource="./File:Foobar.jpg" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></a><figcaption>Title</figcaption></figure>
10200 Image with frame and link
10202 parsoid=wt2html,wt2wt,html2html
10204 [[File:Foobar.jpg|frame|left|This is a test image [[Main Page]]]]
10206 <div class="thumb tleft"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption">This is a test image <a href="/wiki/Main_Page" title="Main Page">Main Page</a></div></div></div>
10209 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="Main_Page">Main Page</a></figcaption></figure>
10213 Image with frame and link and explicit alt
10215 parsoid=wt2html,wt2wt,html2html
10217 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]|alt=Altitude]]
10219 <div class="thumb tleft"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Altitude" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption">This is a test image <a href="/wiki/Main_Page" title="Main Page">Main Page</a></div></div></div>
10222 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img alt="Altitude" resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a><figcaption>This is a test image <a rel="mw:WikiLink" href="Main_Page">Main Page</a></figcaption></figure>
10226 Image with wiki markup in implicit alt
10228 parsoid=wt2html,wt2wt,html2html
10230 [[Image:Foobar.jpg|testing '''bold''' in alt]]
10232 [[Image:Foobar.jpg|alt=testing '''bold''' in alt]]
10234 <p><a href="/wiki/File:Foobar.jpg" class="image" title="testing bold in alt"><img alt="testing bold in alt" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10235 </p><p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="testing bold in alt" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10238 <p><span class="mw-default-size" typeof="mw:Image" data-mw="{"caption":"testing '''bold''' in alt"}"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10239 <p><span class="mw-default-size" typeof="mw:Image"><a href="File:Foobar.jpg"><img alt="testing bold in alt" resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10242 ###################
10243 # Conflicting image format options.
10244 # First option specified should 'win'.
10245 # All three cases in each test should be identical.
10248 Image with 'frameless' first.
10250 parsoid=wt2html,wt2wt,html2html
10252 [[File:Foobar.jpg|frameless|caption]]
10254 [[File:Foobar.jpg|frameless|frame|caption]]
10256 [[File:Foobar.jpg|frameless|thumb|caption]]
10258 <p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a>
10259 </p><p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a>
10260 </p><p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a>
10263 <p><span class="mw-default-size" typeof="mw:Image/Frameless" data-mw='{"caption":"caption"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a></span></p>
10264 <p><span class="mw-default-size" typeof="mw:Image/Frameless" data-mw='{"caption":"caption"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a></span></p>
10265 <p><span class="mw-default-size" typeof="mw:Image/Frameless" data-mw='{"caption":"caption"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a></span></p>
10269 Image with 'frame' first.
10271 parsoid=wt2html,wt2wt,html2html
10273 [[File:Foobar.jpg|frame|caption]]
10274 [[File:Foobar.jpg|frame|frameless|caption]]
10275 [[File:Foobar.jpg|frame|thumb|caption]]
10277 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption">caption</div></div></div>
10278 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption">caption</div></div></div>
10279 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption">caption</div></div></div>
10282 <figure class="mw-default-size" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a><figcaption>caption</figcaption></figure>
10286 Image with 'thumb' first.
10288 parsoid=wt2html,wt2wt,html2html
10290 [[File:Foobar.jpg|thumb|caption]]
10291 [[File:Foobar.jpg|thumb|frameless|caption]]
10292 [[File:Foobar.jpg|thumb|frame|caption]]
10294 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10295 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10296 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10299 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
10302 ###################
10304 # See https://www.mediawiki.org/wiki/Help:Images#Size_and_frame
10305 # and https://bugzilla.wikimedia.org/show_bug.cgi?id=62258
10306 # Foobar has actual size of 1941x220
10307 # 1. Thumbs & frameless always reduce, can't be enlarged unless it's
10308 # a scalable format.
10309 # 2. Framed images always ignore size options; always render at default size.
10310 # 3. "Unspecified format" and border are the only types which can be
10314 Image: "unspecified format" and border enlarge
10316 parsoid=wt2html,wt2wt,html2html
10318 [[File:Foobar.jpg|2000px]]
10320 [[File:Foobar.jpg|border|2000px]]
10322 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="2000" height="227" /></a>
10323 </p><p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="2000" height="227" class="thumbborder" /></a>
10326 <p><span typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="227" width="2000"/></a></span></p>
10327 <p><span class="mw-image-border" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="227" width="2000"/></a></span></p>
10331 Image: "unspecified format" and border reduce
10333 parsoid=wt2html,wt2wt,html2html
10335 [[File:Foobar.jpg|1000px]]
10337 [[File:Foobar.jpg|border|1000px]]
10339 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/1000px-Foobar.jpg" width="1000" height="113" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/1500px-Foobar.jpg 1.5x, http://example.com/images/3/3a/Foobar.jpg 2x" /></a>
10340 </p><p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/1000px-Foobar.jpg" width="1000" height="113" class="thumbborder" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/1500px-Foobar.jpg 1.5x, http://example.com/images/3/3a/Foobar.jpg 2x" /></a>
10343 <p><span typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="113" width="1000"/></a></span></p>
10344 <p><span class="mw-image-border" typeof="mw:Image"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="113" width="1000"/></a></span></p>
10348 Image: thumbs reduce
10350 parsoid=wt2html,wt2wt,html2html
10352 [[File:Foobar.jpg|thumb|50px]]
10354 <div class="thumb tright"><div class="thumbinner" style="width:52px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" width="50" height="6" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/75px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/100px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>
10357 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="6" width="50"/></a></figure>
10361 Image: bitmap thumbs can't be enlarged past original size, but vector can.
10363 parsoid=wt2html,wt2wt,html2html
10365 [[File:Foobar.jpg|thumb|2000px]]
10367 [[File:Foobar.svg|thumb|2000px]]
10369 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>
10370 <div class="thumb tright"><div class="thumbinner" style="width:2002px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="Foobar.svg" src="http://example.com/images/thumb/f/ff/Foobar.svg/2000px-Foobar.svg.png" width="2000" height="1500" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/3000px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/4000px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div></div></div></div>
10373 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure>
10374 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" height="1500" width="2000"/></a></figure>
10378 Image: frameless can reduce in size
10380 parsoid=wt2html,wt2wt,html2html
10382 [[File:Foobar.jpg|frameless|50px]]
10384 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" width="50" height="6" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/75px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/100px-Foobar.jpg 2x" /></a>
10387 <p><span typeof="mw:Image/Frameless"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="6" width="50"/></a></span></p>
10391 Image: bitmap frameless can't be enlarged past original size, but vector can
10393 parsoid=wt2html,wt2wt,html2html
10395 [[File:Foobar.jpg|frameless|2000px]]
10397 [[File:Foobar.svg|frameless|2000px]]
10399 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10400 </p><p><a href="/wiki/File:Foobar.svg" class="image"><img alt="Foobar.svg" src="http://example.com/images/thumb/f/ff/Foobar.svg/2000px-Foobar.svg.png" width="2000" height="1500" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/3000px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/4000px-Foobar.svg.png 2x" /></a>
10403 <p><span typeof="mw:Image/Frameless"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10404 <p><span typeof="mw:Image/Frameless"><a href="File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" height="1500" width="2000"/></a></span></p>
10408 Image: framed images are always unscaled.
10410 parsoid=wt2html,wt2wt,html2html
10412 [[File:Foobar.jpg|frame]]
10414 [[File:Foobar.jpg|frame|50px]]
10416 [[File:Foobar.jpg|frame|50x50px]]
10418 [[File:Foobar.jpg|frame|2000px]]
10420 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"></div></div></div>
10421 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"></div></div></div>
10422 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"></div></div></div>
10423 <div class="thumb tright"><div class="thumbinner" style="width:1943px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="thumbimage" /></a> <div class="thumbcaption"></div></div></div>
10426 <figure class="mw-default-size" typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure><figure typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure><figure typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure><figure typeof="mw:Image/Frame"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></figure>
10429 ###################
10432 Link to image page- image page normally doesn't exists, hence edit link
10433 Add test with existing image page
10434 #<p><a href="/wiki/File:Test" title="Image:Test">Image:test</a>
10438 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">Image:test</a>
10443 bug 18784 Link to non-existent image page with caption should use caption as link text
10445 [[:Image:test|caption]]
10447 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">caption</a>
10452 Frameless image caption with a free URL
10454 [[File:Foobar.jpg|http://example.com]]
10456 <p><a href="/wiki/File:Foobar.jpg" class="image" title="http://example.com"><img alt="http://example.com" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10459 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"http://example.com"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10463 Thumbnail image caption with a free URL
10467 [[File:Foobar.jpg|thumb|http://example.com]]
10469 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
10472 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></figcaption></figure>
10476 Thumbnail image caption with a free URL and explicit alt
10479 parsoid=wt2html,wt2wt,html2html
10481 [[File:Foobar.jpg|thumb|http://example.com|alt=Alteration]]
10483 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Alteration" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
10486 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img alt="Alteration" resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></figcaption></figure>
10490 SVG thumbnails with no language set
10493 [[File:Foobar.svg|thumb|caption]]
10495 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10498 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" height="165" width="220"/></a><figcaption>caption</figcaption></figure>
10502 SVG thumbnails with language de
10504 parsoid=wt2html,wt2wt,html2html
10506 [[File:Foobar.svg|thumb|caption|lang=de]]
10508 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=File:Foobar.svg&lang=de" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/langde-180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/langde-270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/langde-360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10511 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" lang="de" height="165" width="220"/></a><figcaption>caption</figcaption></figure>
10515 SVG thumbnails with invalid language code
10517 parsoid=wt2html,wt2wt,html2html
10519 [[File:Foobar.svg|thumb|caption|lang=invalid.language.code]]
10521 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.svg" class="image"><img alt="" src="http://example.com/images/thumb/f/ff/Foobar.svg/180px-Foobar.svg.png" width="180" height="135" class="thumbimage" srcset="http://example.com/images/thumb/f/ff/Foobar.svg/270px-Foobar.svg.png 1.5x, http://example.com/images/thumb/f/ff/Foobar.svg/360px-Foobar.svg.png 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.svg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>lang=invalid.language.code</div></div></div>
10524 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" height="165" width="220"/></a><figcaption>lang=invalid.language.code</figcaption></figure>
10528 BUG 1887: A ISBN with a thumbnail
10530 [[File:Foobar.jpg|thumb|ISBN 1235467890]]
10532 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/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="/wiki/Special:BookSources/1235467890" class="internal mw-magiclink-isbn">ISBN 1235467890</a></div></div></div>
10535 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption><a href="Special:BookSources/1235467890" rel="mw:ExtLink">ISBN 1235467890</a></figcaption></figure>
10539 BUG 1887: A RFC with a thumbnail
10541 [[File:Foobar.jpg|thumb|This is RFC 12354]]
10543 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/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 class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc12354">RFC 12354</a></div></div></div>
10546 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>This is <a href="//tools.ietf.org/html/rfc12354" rel="mw:ExtLink">RFC 12354</a></figcaption></figure>
10550 BUG 1887: A mailto link with a thumbnail
10552 [[File:Foobar.jpg|thumb|Please mailto:nobody@example.com]]
10554 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/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 rel="nofollow" class="external free" href="mailto:nobody@example.com">mailto:nobody@example.com</a></div></div></div>
10557 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>Please <a rel="mw:ExtLink" href="mailto:nobody@example.com">mailto:nobody@example.com</a></figcaption></figure>
10560 # Pending resolution to bug 368
10562 BUG 648: Frameless image caption with a link
10564 [[File:Foobar.jpg|text with a [[link]] in it]]
10566 <p><a href="/wiki/File:Foobar.jpg" class="image" title="text with a link in it"><img alt="text with a link in it" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10569 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"text with a [[link]] in it"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10573 BUG 648: Frameless image caption with a link (suffix)
10575 [[File:Foobar.jpg|text with a [[link]]foo in it]]
10577 <p><a href="/wiki/File:Foobar.jpg" class="image" title="text with a linkfoo in it"><img alt="text with a linkfoo in it" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10580 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"text with a [[link]]foo in it"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10584 BUG 648: Frameless image caption with an interwiki link
10586 [[File:Foobar.jpg|text with a [[MeatBall:Link]] in it]]
10588 <p><a href="/wiki/File:Foobar.jpg" class="image" title="text with a MeatBall:Link in it"><img alt="text with a MeatBall:Link in it" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10591 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"text with a [[MeatBall:Link]] in it"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10595 BUG 648: Frameless image caption with a piped interwiki link
10597 [[File:Foobar.jpg|text with a [[MeatBall:Link|link]] in it]]
10599 <p><a href="/wiki/File:Foobar.jpg" class="image" title="text with a link in it"><img alt="text with a link in it" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10602 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"text with a [[MeatBall:Link|link]] in it"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10606 Escape HTML special chars in image alt text
10608 [[File:Foobar.jpg|& < > "]]
10610 <p><a href="/wiki/File:Foobar.jpg" class="image" title="& < > ""><img alt="& < > "" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10613 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"& < > \""}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10617 BUG 499: Alt text should have Ӓ, not &1234;
10619 [[File:Foobar.jpg|♀]]
10621 <p><a href="/wiki/File:Foobar.jpg" class="image" title="♀"><img alt="♀" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10624 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"&#9792;"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10628 Broken image caption with link
10630 parsoid=wt2html,wt2wt,html2html
10632 [[Image:Foobar.jpg|thumb|This is a broken caption. But [[Main Page|this]] is just an ordinary link.
10634 <p>[[Image:Foobar.jpg|thumb|This is a broken caption. But <a href="/wiki/Main_Page" title="Main Page">this</a> is just an ordinary link.
10637 <p>[[Image:Foobar.jpg|thumb|This is a broken caption. But <a rel="mw:WikiLink" href="Main_Page">this</a> is just an ordinary link.</p>
10641 Image caption containing another image
10643 [[File:Foobar.jpg|thumb|This is a caption with another [[File:Thumb.png|image]] inside it!]]
10645 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/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 caption with another <a href="/wiki/File:Thumb.png" class="image" title="image"><img alt="image" src="http://example.com/images/e/ea/Thumb.png" width="135" height="135" /></a> inside it!</div></div></div>
10648 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>This is a caption with another <span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"image"}'><a href="File:Thumb.png"><img resource="./File:Thumb.png" src="//example.com/images/e/ea/Thumb.png" height="135" width="135"/></a></span> inside it!</figcaption></figure>
10652 Image: caption containing a newline
10654 [[File:Foobar.jpg|This
10657 <p><a href="/wiki/File:Foobar.jpg" class="image" title="This *is some text"><img alt="This *is some text" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
10660 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"This\n*is some text"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10664 Image: caption containing leading space
10665 (The leading space should not trigger nowiki escaping in wt2wt mode)
10667 [[File:Foobar.jpg|thumb| bar]]
10669 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>bar</div></div></div>
10672 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption> bar</figcaption></figure>
10676 Image: caption containing a table
10678 parsoid=wt2html,wt2wt,html2html
10680 [[Image:Foobar.jpg|thumb|200px|This is an example image thumbnail caption with a table
10686 and some more text.]]
10688 <div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/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 an example image thumbnail caption with a table <table> <tr> <th> Foo </th> <th> Bar </th></tr> <tr> <td> Foo1 </td> <td> Bar1 </td></tr></table> and some more text.</div></div></div>
10691 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="23" width="200"/></a><figcaption>This is an example image thumbnail caption with a table
10694 <tr><th>Foo </th><th>Bar</th></tr>
10697 <td>Bar1</td></tr></tbody></table>and some more text.</figcaption></figure>
10701 Bug 3090: External links other than http: in image captions
10703 [[File:Foobar.jpg|thumb|200x200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
10705 <div class="thumb tright"><div class="thumbinner" style="width:202px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/300px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/400px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/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 rel="nofollow" class="external text" href="irc://example.net">irc</a> and <a rel="nofollow" class="external text" href="https://example.com">Secure</a> ext links in it.</div></div></div>
10708 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="23" width="200"/></a><figcaption>This caption has <a rel="mw:ExtLink" href="irc://example.net">irc</a> and <a rel="mw:ExtLink" href="https://example.com">Secure</a> ext links in it.</figcaption></figure>
10714 parsoid=wt2html,wt2wt,html2html
10716 [[Image:foobar.jpg|a|class=b]]
10718 <p><a href="/wiki/File:Foobar.jpg" class="image" title="a"><img alt="a" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" class="b" /></a>
10721 <p><span class="mw-default-size b" typeof="mw:Image" data-mw='{"caption":"a"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a></span></p>
10725 Localized image handling (1).
10727 parsoid=wt2html,wt2wt,html2html
10730 [[Archivo:Foobar.jpg|izquierda|enlace=foo|caption]]
10732 <div class="floatleft"><a href="/wiki/Foo" title="caption"><img alt="caption" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
10735 <figure class="mw-default-size mw-halign-left" typeof="mw:Image"><a href="./Foo"><img resource="./Archivo:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941"/></a><figcaption>caption</figcaption></figure>
10739 Localized image handling (2).
10742 parsoid=wt2html,wt2wt,html2html
10745 [[Archivo:Foobar.jpg|miniatura|izquierda|enlace=foo|caption]]
10747 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/Foo" title="Foo"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/Archivo:Foobar.jpg" class="internal" title="Aumentar"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10750 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="./Foo"><img resource="./Archivo:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
10754 "border", "frameless" and "class" attributes on an image.
10757 parsoid=wt2html,wt2wt,html2html
10759 [[File:Foobar.jpg|frameless|border|class=extra|caption]]
10761 <p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="extra thumbborder" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a>
10764 <p><span class="mw-default-size mw-image-border extra" typeof="mw:Image/Frameless" data-mw='{"caption":"caption"}'><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a></span></p>
10767 # Note that 'right' is the default alignment, despite the misspelled 'righ' below
10769 Invalid image attributes (bug 62500)
10772 parsoid=wt2html,wt2wt,html2html
10774 [[File:Foobar.jpg|thumb|float|left|caption]]
10776 [[File:Foobar.jpg|thumb|righ|caption]]
10778 [[File:Foobar.jpg|bogus1|thumb|bogus2|left|bogus3|caption]]
10780 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10781 <div class="thumb tright"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10782 <div class="thumb tleft"><div class="thumbinner" style="width:222px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" width="220" height="25" class="thumbimage" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/330px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/440px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>caption</div></div></div>
10785 <figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size mw-halign-left" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>caption</figcaption></figure>
10791 #REDIRECT [[File:Barfoo.jpg]]
10797 [[Image:Barfoo.jpg]]
10799 <p><a href="/wiki/File:Barfoo.jpg" title="File:Barfoo.jpg">File:Barfoo.jpg</a>
10804 Missing image with uploads disabled
10808 [[Image:Foobaz.jpg]]
10810 <p><a href="/wiki/File:Foobaz.jpg" title="File:Foobaz.jpg">File:Foobaz.jpg</a>
10814 # Parsoid-specific testing for images
10815 # https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
10816 # Currently imperfect due to a flaw in the Parsoid testrunner
10818 # THESE TESTS SHOULD BE MOVED UP and merged with the php-specific
10822 Parsoid-specific image handling - simple image with size and middle alignment
10824 [[File:Foobar.jpg|middle|50px]]
10826 <p><span class="mw-valign-middle" typeof="mw:Image">
10827 <a href="File:Foobar.jpg">
10828 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
10835 Parsoid-specific image handling - simple image with size, middle alignment,
10836 non-standard namespace alias
10838 parsoid=wt2wt,wt2html,html2html
10840 [[Image:Foobar.jpg|middle|50px]]
10842 <p><span class="mw-valign-middle" typeof="mw:Image">
10843 <a href="File:Foobar.jpg">
10844 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
10851 Parsoid-specific image handling - simple image with size and middle alignment
10854 [[File:Foobar.jpg|50px|middle]]
10856 <p><span class="mw-valign-middle" typeof="mw:Image" data-parsoid='{"optList":[{"ck":"width","ak":"50px"},{"ck":"middle","ak":"middle"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
10860 Parsoid-specific image handling - simple image with size and middle alignment
10861 and non-standard namespace name
10863 parsoid=wt2html,wt2wt,html2html
10865 [[Image:Foobar.jpg|50px|middle]]
10867 <p><span class="mw-valign-middle" typeof="mw:Image">
10868 <a href="File:Foobar.jpg">
10869 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
10876 Parsoid-specific image handling - simple image with both sizes, a baseline alignment, and a caption
10878 [[File:Foobar.jpg|500x10px|baseline|caption]]
10880 <p><span class="mw-valign-baseline" typeof="mw:Image" data-mw='{"caption":"caption"}' data-parsoid='{"optList":[{"ck":"width","ak":"500x10px"},{"ck":"baseline","ak":"baseline"},{"ck":"caption","ak":"caption"}],"size":"500x10"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/89px-Foobar.jpg" height="10" width="89" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"10","width":"89"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
10884 Parsoid-specific image handling - simple image with border and size spec
10886 [[File:Foobar.jpg|50px|border|caption]]
10888 <p><span class="mw-image-border" typeof="mw:Image" data-mw='{"caption":"caption"}' data-parsoid='{"optList":[{"ck":"width","ak":"50px"},{"ck":"border","ak":"border"},{"ck":"caption","ak":"caption"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
10892 Parsoid-specific image handling - thumbnail with halign, valign, and caption
10894 [[File:Foobar.jpg|left|baseline|thumb|caption content]]
10896 <figure class="mw-default-size mw-halign-left mw-valign-baseline" typeof="mw:Image/Thumb">
10897 <a href="File:Foobar.jpg">
10898 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" height="25" width="220" />
10900 <figcaption>caption content</figcaption>
10905 Parsoid-specific image handling - thumbnail with halign, valign, and caption
10908 [[File:Foobar.jpg|thumb|left|baseline|caption content]]
10910 <figure class="mw-default-size mw-halign-left mw-valign-baseline" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"left","ak":"left"},{"ck":"baseline","ak":"baseline"},{"ck":"caption","ak":"caption content"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" height="25" width="220" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"25","width":"220"},"sa":{"resource":"File:Foobar.jpg"}}'/></a><figcaption>caption content</figcaption></figure>
10914 Parsoid-specific image handling - thumbnail with specific size, halign, valign, and caption
10916 [[Image:Foobar.jpg|right|middle|thumb|50x50px|caption]]
10918 <figure class="mw-halign-right mw-valign-middle" typeof="mw:Image/Thumb">
10919 <a href="File:Foobar.jpg">
10920 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" />
10922 <figcaption>caption</figcaption>
10927 Parsoid-specific image handling - thumbnail with specific size, halign,
10928 valign, and caption (existing content)
10930 [[File:Foobar.jpg|thumb|50x50px|right|middle|caption]]
10932 <figure class="mw-halign-right mw-valign-middle" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"width","ak":"50x50px"},{"ck":"right","ak":"right"},{"ck":"middle","ak":"middle"},{"ck":"caption","ak":"caption"}],"size":"50x50"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"6","width":"50"},"sa":{"resource":"File:Foobar.jpg"}}'/></a><figcaption>caption</figcaption></figure>
10936 Parsoid-specific image handling - framed image with specific size and caption
10939 parsoid=wt2html,wt2wt,html2html
10941 [[File:Foobar.jpg|frame|500x50px|caption]]
10943 <figure typeof="mw:Image/Frame">
10944 <a href="File:Foobar.jpg">
10945 <img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941" />
10947 <figcaption>caption</figcaption>
10952 Parsoid-specific image handling - framed image with specific size, halign, valign, and caption
10955 parsoid=wt2html,wt2wt,html2html
10957 [[File:Foobar.jpg|left|baseline|frame|500x50px|caption]]
10959 <figure class="mw-halign-left mw-valign-baseline" typeof="mw:Image/Frame">
10960 <a href="File:Foobar.jpg">
10961 <img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941" />
10963 <figcaption>caption</figcaption>
10968 Parsoid-specific image handling - frameless image with specific size, border, and caption
10970 [[File:Foobar.jpg|frameless|442x50px|border|caption]]
10972 <p><span class="mw-image-border" typeof="mw:Image/Frameless" data-mw='{"caption":"caption"}' data-parsoid='{"optList":[{"ck":"frameless","ak":"frameless"},{"ck":"width","ak":"442x50px"},{"ck":"border","ak":"border"},{"ck":"caption","ak":"caption"}],"size":"442x50"}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/442px-Foobar.jpg" height="50" width="442" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"50","width":"442"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></span></p>
10976 Parsoid-specific image handling - simple image with a formatted caption
10978 [[File:Foobar.jpg|<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>]]
10980 <p><span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>"}'>
10981 <a href="File:Foobar.jpg">
10982 <img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="220" width="1941">
10987 Parsoid-specific image handling - caption with a template in it
10989 [[File:Foobar.jpg|thumb|200x23px|This caption has a {{echo|transclusion}} in it.]]
10991 <figure typeof="mw:Image/Thumb"><a href="./File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/200px-Foobar.jpg" height="23" width="200"></a><figcaption>This caption has a <span about="#mwt1" typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"transclusion"}},"i":0}}]}">transclusion</span> in it.</figcaption></figure>
10995 Parsoid-specific image handling - caption with unbalanced tags in it
10997 parsoid=wt2html,wt2wt,html2html
11000 [[File:Foobar.jpg|thumb|200x200px|This caption has a <center>unbalanced tag in it.]]
11004 <figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="23" width="200"></a><figcaption>This caption has a <center>unbalanced tag in it.</center></figcaption></figure>
11009 Parsoid-specific image handling - empty caption (1)
11011 parsoid=wt2html,wt2wt
11013 [[File:Foobar.jpg|thumb|]]
11015 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption></figcaption></figure>
11018 # empty captions don't get serialized unless we're in the "round trip" case
11020 Parsoid-specific image handling - empty caption (2)
11024 <figure class="mw-default-size" typeof="mw:Image/Thumb">
11025 <a href="File:Foobar.jpg">
11026 <img resource="./File:Foobar.jpg"
11027 src="//example.com/images/3/3a/Foobar.jpg"
11028 height="25" width="220"/>
11030 <figcaption></figcaption>
11033 [[File:Foobar.jpg|thumb]]
11037 Parsoid-specific image handling - whitespace caption
11039 [[File:Foobar.jpg|thumb| ]]
11041 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption> </figcaption></figure>
11045 Parsoid-specific image handling - lang option
11048 [[File:Foobar.svg|lang=de|caption]]
11052 <span class="mw-default-size" typeof="mw:Image" data-mw='{"caption":"caption"}'><a href="./File:Foobar.svg"><img resource="./File:Foobar.svg" src="//example.com/images/f/ff/Foobar.svg" lang="de" height="180" width="240"/></a></span>
11061 Subpage test/subpage
11069 subpage title=[[Subpage test]]
11073 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a>
11078 Subpage noslash link
11080 subpage title=[[Subpage test]]
11084 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">subpage</a>
11088 # TODO: make this PHP-parser compatible!
11090 Relative subpage noslash link
11092 parsoid=wt2wt,wt2html,html2html
11093 subpage title=[[Subpage test/1/2/3/4]]
11099 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage/">subpage</a></p>
11100 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage">Subpage_test/1/2/subpage</a></p>
11104 Parsoid: dot-slash prefixed wikilinks
11114 </p><p>[[././baz/]]
11119 </p><p>[[././baz/]]
11124 Render invalid page names as plain text (bug 51090)
11137 [[{{echo|./../foo}}|bar]]
11138 [[{{echo|foo/.}}|bar]]
11139 [[{{echo|foo/..}}|bar]]
11140 [[{{echo|foo~~~~bar}}]]
11141 [[{{echo|foo>bar}}]]
11142 [[{{echo|foo././bar}}]]
11143 [[{{echo|foo{bar}}]]
11144 [[{{echo|foo}bar}}]]
11145 [[{{echo|foo[bar}}]]
11146 [[{{echo|foo]bar}}]]
11147 [[{{echo|foo<bar}}]]
11149 <p>[[./../foo|bar]]
11159 </p><p>[[./../foo|bar]]
11172 <p>[[./../foo|bar]][[foo�|bar]][[foo/.|bar]][[foo/..|bar]][[foo~~~bar]][[foo>bar]][[foo[bar]][[.]][[..]][[foo././bar]]</p>
11173 <p>[[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"./../foo"}},"i":0}}]}'>./../foo</span>|bar]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/."}},"i":0}}]}'>foo/.</span>|bar]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo/.."}},"i":0}}]}'>foo/..</span>|bar]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo~~~~bar"}},"i":0}}]}'>foo~~~~bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo>bar"}},"i":0}}]}'>foo>bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo././bar"}},"i":0}}]}'>foo././bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo{bar"}},"i":0}}]}'>foo{bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo}bar"}},"i":0}}]}'>foo}bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo[bar"}},"i":0}}]}'>foo[bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo]bar"}},"i":0}}]}'>foo]bar</span>]][[<span typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo<bar"}},"i":0}}]}'>foo<bar</span>]]</p>
11181 <p><a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a>
11186 BUG 561: {{/Subpage}}
11188 subpage title=[[Page]]
11192 <p><a href="/index.php?title=Page/Subpage&action=edit&redlink=1" class="new" title="Page/Subpage (page does not exist)">Page/Subpage</a>
11200 Category:MediaWiki User's Guide
11208 [[:Category:MediaWiki User's Guide]]
11210 <p><a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">Category:MediaWiki User's Guide</a>
11219 [[Category:MediaWiki User's Guide]]
11221 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
11225 PAGESINCATEGORY invalid title fatal (r33546 fix)
11227 {{PAGESINCATEGORY:<bogus>}}
11234 Category with different sort key
11238 [[Category:MediaWiki User's Guide|Foo]]
11240 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
11244 Category with identical sort key
11248 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
11250 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
11254 Category with empty sort key
11259 [[Category:MediaWiki User's Guide|]]
11261 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
11265 Category with empty sort key and parentheses
11270 [[Category:Foo (bar)|]]
11272 [[Category:Foo (bar)|Foo]]
11276 Category with link tail
11281 123[[Category:Foo]]456
11283 123[[Category:Foo]]456
11287 Category with template
11292 [[Category:{{echo|Foo}}]]
11294 [[Category:{{echo|Foo}}]]
11298 Category with template in sort key
11303 [[Category:Foo|{{echo|Bar}}]]
11305 [[Category:Foo|{{echo|Bar}}]]
11309 Category with template in sort key and title
11314 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
11316 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
11320 Category / paragraph interactions
11322 Foo [[Category:Baz]] Bar
11324 Foo [[Category:Baz]]
11332 [[Category:Baz]] Bar
11345 {{echo|[[Category:Baz]]}}
11360 Parsoid: Serialize link to category page with colon escape
11366 [[:Category:Foo|Bar]]
11369 <a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a>
11370 <a rel="mw:WikiLink" href="Category:Foo">Bar</a>
11375 Parsoid: Link prefix/suffixes aren't applied to category links
11377 parsoid=wt2html,wt2wt,html2html
11382 <p>x<link rel="mw:PageProp/Category" href="Category:Foo">y</p>
11386 Parsoid: Serialize link to file page with colon escape
11392 [[:File:Foo.png|Bar]]
11395 <a rel="mw:WikiLink" href="File:Foo.png">File:Foo.png</a>
11396 <a rel="mw:WikiLink" href="File:Foo.png">Bar</a>
11401 Parsoid: Serialize a genuine category link without colon escape
11406 [[Category:Foo|Bar]]
11408 <link rel="mw:PageProp/Category" href="Category:Foo">
11409 <link rel="mw:PageProp/Category" href="Category:Foo#Bar">
11413 Parsoid: Defaultsort
11417 {{DEFAULTSORT:Foo}}
11419 <meta property="mw:PageProp/categorydefaultsort" content="Foo"/>
11423 ### Inter-language links
11426 Inter-language links
11432 [[zh:食品]]
11434 es:Alimento fr:Nourriture zh:食品
11438 Duplicate interlanguage links (bug 24502)
11454 Basic section headings
11461 ===Smaller headline===
11464 <h2><span class="mw-headline" id="Headline_1">Headline 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Headline 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11467 <h2><span class="mw-headline" id="Headline_2">Headline 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Headline 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11470 <h3><span class="mw-headline" id="Smaller_headline">Smaller headline</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Smaller headline">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11476 Section headings with TOC
11479 === Subheadline 1 ===
11480 ===== Skipping a level =====
11481 ====== Skipping a level ======
11485 ===Another headline===
11487 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11489 <li class="toclevel-1 tocsection-1"><a href="#Headline_1"><span class="tocnumber">1</span> <span class="toctext">Headline 1</span></a>
11491 <li class="toclevel-2 tocsection-2"><a href="#Subheadline_1"><span class="tocnumber">1.1</span> <span class="toctext">Subheadline 1</span></a>
11493 <li class="toclevel-3 tocsection-3"><a href="#Skipping_a_level"><span class="tocnumber">1.1.1</span> <span class="toctext">Skipping a level</span></a>
11495 <li class="toclevel-4 tocsection-4"><a href="#Skipping_a_level_2"><span class="tocnumber">1.1.1.1</span> <span class="toctext">Skipping a level</span></a></li>
11502 <li class="toclevel-1 tocsection-5"><a href="#Headline_2"><span class="tocnumber">2</span> <span class="toctext">Headline 2</span></a>
11504 <li class="toclevel-2 tocsection-6"><a href="#Another_headline"><span class="tocnumber">2.1</span> <span class="toctext">Another headline</span></a></li>
11510 <h2><span class="mw-headline" id="Headline_1">Headline 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Headline 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11511 <h3><span class="mw-headline" id="Subheadline_1">Subheadline 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Subheadline 1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11512 <h5><span class="mw-headline" id="Skipping_a_level">Skipping a level</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Skipping a level">edit</a><span class="mw-editsection-bracket">]</span></span></h5>
11513 <h6><span class="mw-headline" id="Skipping_a_level_2">Skipping a level</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Skipping a level">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11514 <h2><span class="mw-headline" id="Headline_2">Headline 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Headline 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11517 <h3><span class="mw-headline" id="Another_headline">Another headline</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: Another headline">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11521 # perl -e 'print "="x$_," Level $_ heading","="x$_,"\n" for 1..10'
11523 Handling of sections up to level 6 and beyond
11526 == Level 2 Heading==
11527 === Level 3 Heading===
11528 ==== Level 4 Heading====
11529 ===== Level 5 Heading=====
11530 ====== Level 6 Heading======
11531 ======= Level 7 Heading=======
11532 ======== Level 8 Heading========
11533 ========= Level 9 Heading=========
11534 ========== Level 10 Heading==========
11536 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11538 <li class="toclevel-1 tocsection-1"><a href="#Level_1_Heading"><span class="tocnumber">1</span> <span class="toctext">Level 1 Heading</span></a>
11540 <li class="toclevel-2 tocsection-2"><a href="#Level_2_Heading"><span class="tocnumber">1.1</span> <span class="toctext">Level 2 Heading</span></a>
11542 <li class="toclevel-3 tocsection-3"><a href="#Level_3_Heading"><span class="tocnumber">1.1.1</span> <span class="toctext">Level 3 Heading</span></a>
11544 <li class="toclevel-4 tocsection-4"><a href="#Level_4_Heading"><span class="tocnumber">1.1.1.1</span> <span class="toctext">Level 4 Heading</span></a>
11546 <li class="toclevel-5 tocsection-5"><a href="#Level_5_Heading"><span class="tocnumber">1.1.1.1.1</span> <span class="toctext">Level 5 Heading</span></a>
11548 <li class="toclevel-6 tocsection-6"><a href="#Level_6_Heading"><span class="tocnumber">1.1.1.1.1.1</span> <span class="toctext">Level 6 Heading</span></a></li>
11549 <li class="toclevel-6 tocsection-7"><a href="#.3D_Level_7_Heading.3D"><span class="tocnumber">1.1.1.1.1.2</span> <span class="toctext">= Level 7 Heading=</span></a></li>
11550 <li class="toclevel-6 tocsection-8"><a href="#.3D.3D_Level_8_Heading.3D.3D"><span class="tocnumber">1.1.1.1.1.3</span> <span class="toctext">== Level 8 Heading==</span></a></li>
11551 <li class="toclevel-6 tocsection-9"><a href="#.3D.3D.3D_Level_9_Heading.3D.3D.3D"><span class="tocnumber">1.1.1.1.1.4</span> <span class="toctext">=== Level 9 Heading===</span></a></li>
11552 <li class="toclevel-6 tocsection-10"><a href="#.3D.3D.3D.3D_Level_10_Heading.3D.3D.3D.3D"><span class="tocnumber">1.1.1.1.1.5</span> <span class="toctext">==== Level 10 Heading====</span></a></li>
11566 <h1><span class="mw-headline" id="Level_1_Heading">Level 1 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Level 1 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
11567 <h2><span class="mw-headline" id="Level_2_Heading">Level 2 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Level 2 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11568 <h3><span class="mw-headline" id="Level_3_Heading">Level 3 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Level 3 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11569 <h4><span class="mw-headline" id="Level_4_Heading">Level 4 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Level 4 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h4>
11570 <h5><span class="mw-headline" id="Level_5_Heading">Level 5 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Level 5 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h5>
11571 <h6><span class="mw-headline" id="Level_6_Heading">Level 6 Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: Level 6 Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11572 <h6><span class="mw-headline" id=".3D_Level_7_Heading.3D">= Level 7 Heading=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=7" title="Edit section: = Level 7 Heading=">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11573 <h6><span class="mw-headline" id=".3D.3D_Level_8_Heading.3D.3D">== Level 8 Heading==</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=8" title="Edit section: == Level 8 Heading==">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11574 <h6><span class="mw-headline" id=".3D.3D.3D_Level_9_Heading.3D.3D.3D">=== Level 9 Heading===</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=9" title="Edit section: === Level 9 Heading===">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11575 <h6><span class="mw-headline" id=".3D.3D.3D.3D_Level_10_Heading.3D.3D.3D.3D">==== Level 10 Heading====</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=10" title="Edit section: ==== Level 10 Heading====">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
11580 TOC regression (bug 9764)
11584 ==== title 1.1.1 ====
11589 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11591 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
11593 <li class="toclevel-2 tocsection-2"><a href="#title_1.1"><span class="tocnumber">1.1</span> <span class="toctext">title 1.1</span></a>
11595 <li class="toclevel-3 tocsection-3"><a href="#title_1.1.1"><span class="tocnumber">1.1.1</span> <span class="toctext">title 1.1.1</span></a></li>
11598 <li class="toclevel-2 tocsection-4"><a href="#title_1.2"><span class="tocnumber">1.2</span> <span class="toctext">title 1.2</span></a></li>
11601 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
11603 <li class="toclevel-2 tocsection-6"><a href="#title_2.1"><span class="tocnumber">2.1</span> <span class="toctext">title 2.1</span></a></li>
11609 <h2><span class="mw-headline" id="title_1">title 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: title 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11610 <h3><span class="mw-headline" id="title_1.1">title 1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: title 1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11611 <h4><span class="mw-headline" id="title_1.1.1">title 1.1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: title 1.1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h4>
11612 <h3><span class="mw-headline" id="title_1.2">title 1.2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: title 1.2">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11613 <h2><span class="mw-headline" id="title_2">title 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: title 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11614 <h3><span class="mw-headline" id="title_2.1">title 2.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: title 2.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11619 TOC with wgMaxTocLevel=3 (bug 6204)
11625 ==== title 1.1.1 ====
11630 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11632 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
11634 <li class="toclevel-2 tocsection-2"><a href="#title_1.1"><span class="tocnumber">1.1</span> <span class="toctext">title 1.1</span></a></li>
11635 <li class="toclevel-2 tocsection-4"><a href="#title_1.2"><span class="tocnumber">1.2</span> <span class="toctext">title 1.2</span></a></li>
11638 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
11640 <li class="toclevel-2 tocsection-6"><a href="#title_2.1"><span class="tocnumber">2.1</span> <span class="toctext">title 2.1</span></a></li>
11646 <h2><span class="mw-headline" id="title_1">title 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: title 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11647 <h3><span class="mw-headline" id="title_1.1">title 1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: title 1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11648 <h4><span class="mw-headline" id="title_1.1.1">title 1.1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: title 1.1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h4>
11649 <h3><span class="mw-headline" id="title_1.2">title 1.2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: title 1.2">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11650 <h2><span class="mw-headline" id="title_2">title 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: title 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11651 <h3><span class="mw-headline" id="title_2.1">title 2.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: title 2.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11656 TOC with wgMaxTocLevel=3 and two level four headings (bug 6204)
11662 ====Section 1.1.1====
11663 ====Section 1.1.1.1====
11666 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11668 <li class="toclevel-1 tocsection-1"><a href="#Section_1"><span class="tocnumber">1</span> <span class="toctext">Section 1</span></a>
11670 <li class="toclevel-2 tocsection-2"><a href="#Section_1.1"><span class="tocnumber">1.1</span> <span class="toctext">Section 1.1</span></a></li>
11673 <li class="toclevel-1 tocsection-5"><a href="#Section_2"><span class="tocnumber">2</span> <span class="toctext">Section 2</span></a></li>
11677 <h2><span class="mw-headline" id="Section_1">Section 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11678 <h3><span class="mw-headline" id="Section_1.1">Section 1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Section 1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11679 <h4><span class="mw-headline" id="Section_1.1.1">Section 1.1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Section 1.1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h4>
11680 <h4><span class="mw-headline" id="Section_1.1.1.1">Section 1.1.1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Section 1.1.1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h4>
11681 <h2><span class="mw-headline" id="Section_2">Section 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Section 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11687 Resolving duplicate section names
11692 <h2><span class="mw-headline" id="Foo_bar">Foo bar</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Foo bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11693 <h2><span class="mw-headline" id="Foo_bar_2">Foo bar</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Foo bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11698 Resolving duplicate section names with differing case (bug 10721)
11703 <h2><span class="mw-headline" id="Foo_bar">Foo bar</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Foo bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11704 <h2><span class="mw-headline" id="Foo_Bar_2">Foo Bar</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Foo Bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11716 Template with sections, __NOTOC__
11723 <h2><span class="mw-headline" id="Section_0">Section 0</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section 0">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11724 <h3><span class="mw-headline" id="Section_1">Section 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Template:Sections&action=edit&section=T-1" title="Template:Sections">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11725 <h2><span class="mw-headline" id="Section_2">Section 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Template:Sections&action=edit&section=T-2" title="Template:Sections">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11726 <h2><span class="mw-headline" id="Section_4">Section 4</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Section 4">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11731 __NOEDITSECTION__ keyword
11737 <h2><span class="mw-headline" id="Section_1">Section 1</span></h2>
11738 <h2><span class="mw-headline" id="Section_2">Section 2</span></h2>
11743 Link inside a section heading
11745 ==Section with a [[Main Page|link]] in it==
11747 <h2><span class="mw-headline" id="Section_with_a_link_in_it">Section with a <a href="/wiki/Main_Page" title="Main Page">link</a> in it</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section with a link in it">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11752 TOC regression (bug 12077)
11759 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11761 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
11763 <li class="toclevel-2 tocsection-2"><a href="#title_1.1"><span class="tocnumber">1.1</span> <span class="toctext">title 1.1</span></a></li>
11766 <li class="toclevel-1 tocsection-3"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a></li>
11770 <h2><span class="mw-headline" id="title_1">title 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: title 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11771 <h3><span class="mw-headline" id="title_1.1">title 1.1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: title 1.1">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
11772 <h2><span class="mw-headline" id="title_2">title 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: title 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11777 BUG 1219 URL next to image (good)
11779 http://example.com [[Image:foobar.jpg]]
11781 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> <a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
11786 Short headings with trailing space should match behavior of Parser::doHeadings (bug 19910)
11789 The line above must have a trailing space!
11792 But just in case it doesn't...
11794 <h1><span class="mw-headline" id=".3D">=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: =">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
11795 <p>The line above must have a trailing space!
11797 <h1><span class="mw-headline" id=".3D_2">=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: =">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
11798 <p>But just in case it doesn't...
11803 Header with special characters (bug 25462)
11805 The tooltips shall not show entities to the user (ie. be double escaped)
11822 <p>The tooltips shall not show entities to the user (ie. be double escaped)
11824 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11826 <li class="toclevel-1 tocsection-1"><a href="#text_.3E_text"><span class="tocnumber">1</span> <span class="toctext">text > text</span></a></li>
11827 <li class="toclevel-1 tocsection-2"><a href="#text_.3C_text"><span class="tocnumber">2</span> <span class="toctext">text < text</span></a></li>
11828 <li class="toclevel-1 tocsection-3"><a href="#text_.26_text"><span class="tocnumber">3</span> <span class="toctext">text & text</span></a></li>
11829 <li class="toclevel-1 tocsection-4"><a href="#text_.27_text"><span class="tocnumber">4</span> <span class="toctext">text ' text</span></a></li>
11830 <li class="toclevel-1 tocsection-5"><a href="#text_.22_text"><span class="tocnumber">5</span> <span class="toctext">text " text</span></a></li>
11834 <h2><span class="mw-headline" id="text_.3E_text">text > text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: text > text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11837 <h2><span class="mw-headline" id="text_.3C_text">text < text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: text < text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11840 <h2><span class="mw-headline" id="text_.26_text">text & text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: text & text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11843 <h2><span class="mw-headline" id="text_.27_text">text ' text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: text ' text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11846 <h2><span class="mw-headline" id="text_.22_text">text " text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: text " text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
11852 Headers with excess '=' characters
11853 (Are similar tests necessary beyond the 1st level?)
11857 =''italic'' heading==
11858 ==''italic'' heading=
11860 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11862 <li class="toclevel-1 tocsection-1"><a href="#foo.3D"><span class="tocnumber">1</span> <span class="toctext">foo=</span></a></li>
11863 <li class="toclevel-1 tocsection-2"><a href="#.3Dfoo"><span class="tocnumber">2</span> <span class="toctext">=foo</span></a></li>
11864 <li class="toclevel-1 tocsection-3"><a href="#italic_heading.3D"><span class="tocnumber">3</span> <span class="toctext"><i>italic</i> heading=</span></a></li>
11865 <li class="toclevel-1 tocsection-4"><a href="#.3Ditalic_heading"><span class="tocnumber">4</span> <span class="toctext">=<i>italic</i> heading</span></a></li>
11869 <h1><span class="mw-headline" id="foo.3D">foo=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: foo=">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
11870 <h1><span class="mw-headline" id=".3Dfoo">=foo</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: =foo">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
11871 <h1><span class="mw-headline" id="italic_heading.3D"><i>italic</i> heading=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: italic heading=">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
11872 <h1><span class="mw-headline" id=".3Ditalic_heading">=<i>italic</i> heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: =italic heading">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
11877 HTML headers vs TOC (bug 23393)
11878 (__NOEDITSECTION__ for clearer output, doesn't matter here)
11890 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11892 <li class="toclevel-1"><a href="#Header_1"><span class="tocnumber">1</span> <span class="toctext">Header 1</span></a>
11894 <li class="toclevel-2 tocsection-1"><a href="#Header_1.1"><span class="tocnumber">1.1</span> <span class="toctext">Header 1.1</span></a></li>
11895 <li class="toclevel-2 tocsection-2"><a href="#Header_1.2"><span class="tocnumber">1.2</span> <span class="toctext">Header 1.2</span></a></li>
11898 <li class="toclevel-1"><a href="#Header_2"><span class="tocnumber">2</span> <span class="toctext">Header 2</span></a>
11900 <li class="toclevel-2 tocsection-3"><a href="#Header_2.1"><span class="tocnumber">2.1</span> <span class="toctext">Header 2.1</span></a></li>
11901 <li class="toclevel-2 tocsection-4"><a href="#Header_2.2"><span class="tocnumber">2.2</span> <span class="toctext">Header 2.2</span></a></li>
11907 <h1><span class="mw-headline" id="Header_1">Header 1</span></h1>
11908 <h2><span class="mw-headline" id="Header_1.1">Header 1.1</span></h2>
11909 <h2><span class="mw-headline" id="Header_1.2">Header 1.2</span></h2>
11910 <h1><span class="mw-headline" id="Header_2">Header 2</span></h1>
11911 <h2><span class="mw-headline" id="Header_2.1">Header 2.1</span></h2>
11912 <h2><span class="mw-headline" id="Header_2.2">Header 2.2</span></h2>
11917 Single-line or multiline-comments can follow headings
11919 parsoid=wt2html,wt2wt
11927 <h2><span class="mw-headline" id="foo">foo</span></h2>
11928 <h2><span class="mw-headline" id="bar">bar</span></h2>
11929 <h2><span class="mw-headline" id="baz">baz</span></h2>
11934 BUG 1219 URL next to image (broken)
11936 http://example.com[[Image:foobar.jpg]]
11938 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
11943 Bug 1186 news: in the middle of text
11945 http://en.wikinews.org/wiki/Wikinews:Workplace
11947 <p><a rel="nofollow" class="external free" href="http://en.wikinews.org/wiki/Wikinews:Workplace">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
11953 Namespaced link must have a title
11962 Namespaced link must have a title (bad fragment version)
11964 [[Project:#fragment]]
11966 <p>[[Project:#fragment]]
11972 ### HTML tags and HTML attributes
11976 div with no attributes
11978 <div>HTML rocks</div>
11980 <div>HTML rocks</div>
11985 div with double-quoted attribute
11987 <div id="rock">HTML rocks</div>
11989 <div id="rock">HTML rocks</div>
11994 div with single-quoted attribute
11996 <div id='rock'>HTML rocks</div>
11998 <div id="rock">HTML rocks</div>
12003 div with unquoted attribute
12005 <div id=rock>HTML rocks</div>
12007 <div id="rock">HTML rocks</div>
12012 div with illegal double attributes
12014 <div id="a" id="b">HTML rocks</div>
12016 <div id="b">HTML rocks</div>
12020 # FIXME: produce empty string instead of "class" in the PHP parser, following
12023 div with empty attribute value, space before equals
12027 <div class =>HTML rocks</div>
12029 <div class="">HTML rocks</div>
12033 # The PHP parser escapes the opening brace to { for some reason, so
12034 # disabled this test for it.
12036 div with braces in attribute value
12040 <div title="{}">Foo</div>
12042 <div title="{}">Foo</div>
12045 # This it very inconsistent in the PHP parser: it returns
12046 # class="class" if there is a space between the name and the equal sign (see
12047 # 'div with empty attribute value, space before equals'), but strips the
12048 # attribute completely if the space is missing. We hope that not much content
12049 # depends on this, so are implementing the behavior below in Parsoid for
12050 # consistencies' sake. Disabled for the PHP parser.
12051 # FIXME: fix this behavior in the PHP parser?
12053 div with empty attribute value, no space before equals
12057 <div class=>HTML rocks</div>
12059 <div class="">HTML rocks</div>
12064 HTML multiple attributes correction
12066 <p class="error" class="awesome">Awesome!</p>
12068 <p class="awesome">Awesome!</p>
12073 Table multiple attributes correction
12076 !+ class="error" class="awesome"| status
12081 <th class="awesome"> status
12089 <DIV ID="x">HTML ROCKS</DIV>
12091 <div id="x">HTML ROCKS</div>
12096 Non-ASCII pseudo-tags are rendered as text
12105 Pseudo-tag with URL 'name' renders as url link
12107 <http://example.com/>
12109 <p><<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>>
12114 text with amp in the middle of nowhere
12118 <p>Remember AT&T?
12123 text with character entity: eacute
12125 I always thought é was a cute letter.
12127 <p>I always thought é was a cute letter.
12132 text with entity-escaped character entity-like string: eacute
12134 I always thought &eacute; was a cute letter.
12136 <p>I always thought &eacute; was a cute letter.
12141 text with undefined character entity: xacute
12143 I always thought &xacute; was a cute letter.
12145 <p>I always thought &xacute; was a cute letter.
12149 # TODO: generalize to PHP parser?
12155 <data value="5">five</data>
12156 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
12157 <mark>This highlighted text</mark>
12159 <p><data value="5">five</data>
12160 <time datetime="2000-01-01T00:00Z">The new millenium started</time>
12161 <mark>This highlighted text</mark></p>
12165 HTML tag with leading space is parsed as text
12169 <p>< div>foo< /div>
12174 ### Nesting tests (see bug 41545, 50604, 51081)
12177 # This test case is fixed in Parsoid by domino 1.0.12. (bug 50604)
12178 # Note that html2wt is considerably more difficult if we use <b> in
12179 # the test case, instead of <big>
12181 Ensure that HTML adoption agency algorithm is properly implemented.
12183 <big>X<big>Y</big>Z</big>
12185 <p><big>X<big>Y</big>Z</big>
12189 # This was bug 41545 in the PHP parser.
12193 <kbd>X<kbd>Y</kbd>Z</kbd>
12195 <p><kbd>X<kbd>Y</kbd>Z</kbd>
12199 # The following cases were bug 51081 in the PHP parser.
12200 # Note that there are some other nestable tags (b, i, etc) which are
12201 # not covered; see bug 51081 for discussion.
12205 <em>X<em>Y</em>Z</em>
12207 <p><em>X<em>Y</em>Z</em>
12212 Nesting of <strong>
12214 <strong>X<strong>Y</strong>Z</strong>
12216 <p><strong>X<strong>Y</strong>Z</strong>
12225 <p><q>X<q>Y</q>Z</q>
12232 <ruby>X<ruby>Y</ruby>Z</ruby>
12234 <p><ruby>X<ruby>Y</ruby>Z</ruby>
12241 <bdo>X<bdo>Y</bdo>Z</bdo>
12243 <p><bdo>X<bdo>Y</bdo>Z</bdo>
12255 [[Media:Foobar.jpg]]
12257 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Media:Foobar.jpg</a>
12262 Media link with text
12264 [[Media:Foobar.jpg|A neat file to look at]]
12266 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">A neat file to look at</a>
12270 # FIXME: this is still bad HTML tag nesting
12272 Media link with nasty text
12273 fixme: doBlockLevels won't wrap this in a paragraph because it contains a div
12275 [[Media:Foobar.jpg|Safe Link<div style=display:none>" onmouseover="alert(document.cookie)" onfoo="</div>]]
12277 <a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Safe Link<div style="display:none">" onmouseover="alert(document.cookie)" onfoo="</div></a>
12282 Media link to nonexistent file (bug 1702)
12284 [[Media:No such.jpg]]
12286 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="No such.jpg">Media:No such.jpg</a>
12291 Image link to nonexistent file (bug 1850 - good)
12293 [[Image:No such.jpg]]
12295 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="File:No such.jpg">File:No such.jpg</a>
12300 :Image link to nonexistent file (bug 1850 - bad)
12302 [[:Image:No such.jpg]]
12304 <p><a href="/index.php?title=File:No_such.jpg&action=edit&redlink=1" class="new" title="File:No such.jpg (page does not exist)">Image:No such.jpg</a>
12311 Character reference normalization in link text (bug 1938)
12313 [[Main Page|this&that]]
12315 <p><a href="/wiki/Main_Page" title="Main Page">this&that</a>
12322 Test for unicode normalization
12324 The page's name is U+05d0 U+05b7, with non-canonical form U+FB2E
12328 (bug 19451) Links should refer to the normalized form.
12336 <p><a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12337 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12338 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12339 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12340 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
12345 Empty attribute crash test (bug 2067)
12347 <font color="">foo</font>
12349 <p><font color="">foo</font>
12354 Empty attribute crash test single-quotes (bug 2067)
12356 <font color=''>foo</font>
12358 <p><font color="">foo</font>
12363 Attribute test: equals, then nothing
12365 <font color=>foo</font>
12367 <p><font>foo</font>
12372 Attribute test: unquoted value
12374 <font color=x>foo</font>
12376 <p><font color="x">foo</font>
12381 Attribute test: unquoted but illegal value (hash)
12383 <font color=#x>foo</font>
12385 <p><font color="#x">foo</font>
12390 Attribute test: no value
12392 <font color>foo</font>
12394 <p><font color="color">foo</font>
12399 Bug 2095: link with three closing brackets
12403 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>]
12406 <p><a rel="mw:WikiLink" href="./Main_Page">Main Page</a>]</p>
12410 Bug 2095: link with pipe and three closing brackets
12412 [[Main Page|link]]]
12414 <p><a href="/wiki/Main_Page" title="Main Page">link</a>]
12417 <p><a rel="mw:WikiLink" href="./Main_Page">link</a>]</p>
12421 Bug 2095: link with pipe and three closing brackets, version 2
12423 [[Main Page|[http://example.com/]]]
12425 <p><a href="/wiki/Main_Page" title="Main Page">[http://example.com/]</a>
12428 <p><a rel="mw:WikiLink" href="./Main_Page">[http://example.com/]</a></p>
12437 Template:Dangerous attribute
12439 " onmouseover="alert(document.cookie)
12443 Template:Dangerous style attribute
12445 border-size: expression(alert(document.cookie))
12451 <div style="float: right; {{{1}}}">Magic div</div>
12455 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
12457 <div title="{{test}}"></div>
12459 <div title="This is a test template"></div>
12464 Bug 2304: HTML attribute safety (dangerous template; 2309)
12466 <div title="{{dangerous attribute}}"></div>
12468 <div title=""></div>
12473 Bug 2304: HTML attribute safety (dangerous style template; 2309)
12475 <div style="{{dangerous style attribute}}"></div>
12477 <div style="/* insecure input */"></div>
12482 Bug 2304: HTML attribute safety (safe parameter; 2309)
12484 {{div style|width: 200px}}
12486 <div style="float: right; width: 200px">Magic div</div>
12491 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
12493 {{div style|width: expression(alert(document.cookie))}}
12495 <div style="/* insecure input */">Magic div</div>
12500 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
12502 {{div style|"><script>alert(document.cookie)</script>}}
12504 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
12509 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
12511 {{div style|" ><script>alert(document.cookie)</script>}}
12513 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
12518 Bug 2304: HTML attribute safety (link)
12520 <div title="[[Main Page]]"></div>
12522 <div title="[[Main Page]]"></div>
12527 Bug 2304: HTML attribute safety (italics)
12529 <div title="''foobar''"></div>
12531 <div title="''foobar''"></div>
12536 Bug 2304: HTML attribute safety (bold)
12538 <div title="'''foobar'''"></div>
12540 <div title="'''foobar'''"></div>
12546 Bug 2304: HTML attribute safety (ISBN)
12548 <div title="ISBN 1234567890"></div>
12550 <div title="ISBN 1234567890"></div>
12555 Bug 2304: HTML attribute safety (RFC)
12557 <div title="RFC 1234"></div>
12559 <div title="RFC 1234"></div>
12564 Bug 2304: HTML attribute safety (PMID)
12566 <div title="PMID 1234567890"></div>
12568 <div title="PMID 1234567890"></div>
12573 Bug 2304: HTML attribute safety (web link)
12575 <div title="http://example.com/"></div>
12577 <div title="http://example.com/"></div>
12582 Bug 2304: HTML attribute safety (named web link)
12584 <div title="[http://example.com/ link]"></div>
12586 <div title="[http://example.com/ link]"></div>
12591 Bug 3244: HTML attribute safety (extension; safe)
12593 <div style="<nowiki>background:blue</nowiki>"></div>
12595 <div style="background:blue"></div>
12600 Bug 3244: HTML attribute safety (extension; unsafe)
12602 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
12604 <div style="/* insecure input */"></div>
12608 # More MSIE fun discovered by Tom Gilder
12611 MSIE CSS safety test: spurious slash
12613 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
12615 <div style="/* insecure input */">evil</div>
12620 MSIE CSS safety test: hex code
12622 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
12624 <div style="/* insecure input */">evil</div>
12629 MSIE CSS safety test: comment in url
12631 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
12633 <div style="background-image:u rl(javascript:alert('boo'))">evil</div>
12638 MSIE CSS safety test: comment in expression
12640 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
12642 <div style="background-image:expres sion(alert('boo4'))">evil4</div>
12647 CSS safety test (all browsers): vertical tab (bug 55332 / CVE-2013-4567)
12649 <p style="font-size: 100px; background-image:url\b(https://www.google.com/images/srpr/logo6w.png)">A</p>
12651 <p style="/* invalid control char */">A</p>
12656 MSIE 6 CSS safety test: Fullwidth (bug 55332)
12658 <p style="font-size: 100px; color: expression((title='XSSed'),'red')">A</p>
12659 <div style="top:EXPRESSION(alert())">B</div>
12661 <p style="/* insecure input */">A</p>
12662 <div style="/* insecure input */">B</div>
12667 MSIE 6 CSS safety test: IPA extensions (bug 55332)
12669 <div style="background-image:uʀʟ(javascript:alert())">A</div>
12670 <p style="font-size: 100px; color: expʀessɪoɴ((title='XSSed'),'red')">B</p>
12672 <div style="/* insecure input */">A</div>
12673 <p style="/* insecure input */">B</p>
12678 MSIE 6 CSS safety test: sup/sub script (bug 55332)
12680 <div style="background-image:url⁽javascript:alert())">A</div>
12681 <div style="background-image:url₍javascript:alert())">B</div>
12682 <p style="font-size: 100px; color: expressioⁿ((title='XSSed'),'red')">C</p>
12684 <div style="/* insecure input */">A</div>
12685 <div style="/* insecure input */">B</div>
12686 <p style="/* insecure input */">C</p>
12694 title="data:text/html,<img src=1 onerror=alert(1)>"
12695 style="-o-link:attr(title);-o-link-source:current">X</div>
12697 <div title="data:text/html,<img src=1 onerror=alert(1)>" style="/* insecure input */">X</div>
12702 MSIE 6 CSS safety test: Repetition markers (bug 55332)
12704 <p style="font-size: 100px; color: expres〱ion((title='XSSed'),'red')">A</p>
12705 <p style="font-size: 100px; color: expresゝion((title='XSSed'),'red')">B</p>
12706 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">C</p>
12707 <p style="font-size: 100px; color: expresヽion((title='XSSed'),'red')">D</p>
12708 <p style="font-size: 100px; color: expresﹽion((title='XSSed'),'red')">E</p>
12709 <p style="font-size: 100px; color: expresﹼion((title='XSSed'),'red')">F</p>
12710 <p style="font-size: 100px; color: expresーion((title='XSSed'),'red')">G</p>
12712 <p style="/* insecure input */">A</p>
12713 <p style="/* insecure input */">B</p>
12714 <p style="/* insecure input */">C</p>
12715 <p style="/* insecure input */">D</p>
12716 <p style="/* insecure input */">E</p>
12717 <p style="/* insecure input */">F</p>
12718 <p style="/* insecure input */">G</p>
12723 Table attribute legitimate extension
12726 !+ style="<nowiki>color:blue</nowiki>"| status
12731 <th style="color:blue"> status
12737 Table attribute safety
12740 !+ style="<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>"| status
12745 <th style="/* insecure input */"> status
12751 CSS line continuation 1
12753 <div style="background-image: u\ rl(test.jpg);"></div>
12755 <div style="/* insecure input */"></div>
12760 CSS line continuation 2
12762 <div style="background-image: u\ rl(test.jpg); "></div>
12764 <div style="/* insecure input */"></div>
12775 Expansion of multi-line templates in attribute values (bug 6255)
12777 <div style="background: {{identity|#00FF00}}">-</div>
12779 <div style="background: #00FF00">-</div>
12785 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
12787 <div style="background:
12790 <div style="background: #00FF00">-</div>
12795 Expansion of multi-line templates in attribute values (bug 6255 sanity check 2)
12797 <div style="background: #00FF00">-</div>
12799 <div style="background: #00FF00">-</div>
12804 ### Parser hooks (see tests/parser/parserTestsParserHook.php for the <tag> extension)
12807 Parser hook: empty input
12820 Parser hook: empty input using terminated empty elements
12833 Parser hook: empty input using terminated empty elements (space before)
12846 Parser hook: basic input
12860 Parser hook: case insensitive
12874 Parser hook: case insensitive, redux
12887 Parser hook: nested tags
12891 <tag><tag></tag></tag>
12902 Parser hook: basic arguments
12904 <tag width=200 height = "100" depth = '50' square></tag>
12912 'square' => 'square',
12919 Parser hook: argument containing a forward slash (bug 5344)
12921 <tag filename='/tmp/bla'></tag>
12926 'filename' => '/tmp/bla',
12933 Parser hook: empty input using terminated empty elements (bug 2374)
12946 # </tag> should be output literally since there is no matching tag that begins it
12948 Parser hook: basic arguments using terminated empty elements (bug 2374)
12950 <tag width=200 height = "100" depth = '50' square/>
12960 'square' => 'square',
12969 ### (see tests/parser/parserTestsParserHook.php for the <statictag> extension)
12973 Parser hook: static parser hook not inside a comment
12975 <statictag>hello, world</statictag>
12976 <statictag action=flush/>
12984 Parser hook: static parser hook inside a comment
12986 <!-- <statictag>hello, world</statictag> -->
12987 <statictag action=flush/>
12993 # Nested template calls; this case was broken by Parser.php rev 1.506,
12997 Template:One-parameter
12999 (My parameter is: {{{1}}})
13003 Template:Map-one-parameter
13005 {{{{{1}}}|{{{2}}}}}
13009 Nested template calls
13011 {{Map-one-parameter|One-parameter|param}}
13013 <p>(My parameter is: param)
13022 Sanitizer: Closing of open tags
13024 <s></s><table></table>
13026 <s></s><table></table>
13031 Sanitizer: Closing of open but not closed tags
13040 Sanitizer: Closing of closed but not open tags
13049 Sanitizer: Closing of closed but not open table tags
13051 Table not started</td></tr></table>
13053 <p>Table not started</td></tr></table>
13058 Sanitizer: Escaping of spaces, multibyte characters, colons & other stuff in id=""
13060 <span id="æ: v">byte</span>[[#æ: v|backlink]]
13062 <p><span id=".C3.A6:_v">byte</span><a href="#.C3.A6:_v">backlink</a>
13067 Sanitizer: Validating the contents of the id attribute (bug 4515)
13073 Something, but definitely not <br id="9" />...
13077 Sanitizer: Validating id attribute uniqueness (bug 4515, bug 6301)
13081 <br id="foo" /><br id="foo" />
13083 Something need to be done. foo-2 ?
13087 Sanitizer: Validating that <meta> and <link> work, but only for Microdata
13090 <meta itemprop="hello" content="world">
13091 <meta http-equiv="refresh" content="5">
13092 <meta itemprop="hello" http-equiv="refresh" content="5">
13093 <link itemprop="hello" href="{{SERVER}}">
13094 <link rel="stylesheet" href="{{SERVER}}">
13095 <link rel="stylesheet" itemprop="hello" href="{{SERVER}}">
13098 <div itemscope="itemscope">
13099 <p> <meta itemprop="hello" content="world" />
13100 <meta http-equiv="refresh" content="5">
13101 <meta itemprop="hello" content="5" />
13103 <link itemprop="hello" href="http://example.org" />
13104 <link rel="stylesheet" href="<a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>">
13105 <link itemprop="hello" href="http://example.org" />
13111 Language converter: output gets cut off unexpectedly (bug 5757)
13115 this bit is safe: }-
13117 but if we add a conversion instance: -{zh-cn:xxx;zh-tw:yyy}-
13119 then we get cut off here: }-
13121 all additional text is vanished
13123 <p>this bit is safe: }-
13124 </p><p>but if we add a conversion instance: xxx
13125 </p><p>then we get cut off here: }-
13126 </p><p>all additional text is vanished
13131 Self closed html pairs (bug 5487)
13134 <center><font id="bug" />Centered text</center>
13135 <div><font id="bug2" />In div text</div>
13137 <center><font id="bug" />Centered text</center>
13138 <div><font id="bug2" />In div text</div>
13147 Punctuation: nbsp before exclamation
13151 <p>C'est grave !
13156 Punctuation: CSS !important (bug 11874)
13158 <div style="width:50% !important">important</div>
13160 <div style="width:50% !important">important</div>
13165 Punctuation: CSS ! important (bug 11874; with space after)
13167 <div style="width:50% ! important">important</div>
13169 <div style="width:50% ! important">important</div>
13175 HTML bullet list, closed tags (bug 5497)
13190 HTML bullet list, unclosed tags (bug 5497)
13209 HTML ordered list, closed tags (bug 5497)
13224 HTML ordered list, unclosed tags (bug 5497)
13243 HTML nested bullet list, closed tags (bug 5497)
13268 HTML nested bullet list, open tags (bug 5497)
13297 HTML nested ordered list, closed tags (bug 5497)
13322 HTML nested ordered list, open tags (bug 5497)
13351 HTML ordered list item with parameters oddity
13353 <ol><li id="fragment">One</li>
13356 <ol><li id="fragment">One</li>
13361 # parsoid doesn't explicitly mark autonumbered links, see bug 53505
13363 bug 5918: autonumbering
13365 [http://first/] [http://second] [ftp://ftp]
13369 [mailto:enclosed@mail.tld With target]
13371 [mailto:enclosed@mail.tld]
13373 mailto:inline@mail.tld
13375 <p><a rel="nofollow" class="external autonumber" href="http://first/">[1]</a> <a rel="nofollow" class="external autonumber" href="http://second">[2]</a> <a rel="nofollow" class="external autonumber" href="ftp://ftp">[3]</a>
13376 </p><p><a rel="nofollow" class="external free" href="ftp://inlineftp">ftp://inlineftp</a>
13377 </p><p><a rel="nofollow" class="external text" href="mailto:enclosed@mail.tld">With target</a>
13378 </p><p><a rel="nofollow" class="external autonumber" href="mailto:enclosed@mail.tld">[4]</a>
13379 </p><p><a rel="nofollow" class="external free" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a>
13382 <p><a rel="mw:ExtLink" href="http://first/"></a> <a rel="mw:ExtLink" href="http://second"></a> <a rel="mw:ExtLink" href="ftp://ftp"></a></p>
13383 <p><a rel="mw:ExtLink" href="ftp://inlineftp">ftp://inlineftp</a></p>
13384 <p><a rel="mw:ExtLink" href="mailto:enclosed@mail.tld">With target</a></p>
13385 <p><a rel="mw:ExtLink" href="mailto:enclosed@mail.tld"></a></p>
13386 <p><a rel="mw:ExtLink" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a></p>
13391 # Security and HTML correctness
13392 # From Nick Jenkins' fuzz testing
13396 Fuzz testing: Parser13
13411 Fuzz testing: Parser14
13416 <h2><span class="mw-headline" id="onmouseover.3D">onmouseover=</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: onmouseover=">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
13417 http://<div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13419 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
13427 Fuzz testing: Parser14-table
13432 <h2><span class="mw-headline" id="a">a</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: a">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
13433 <table style="__TOC__">
13439 # Known to produce bogus xml (extra </td>)
13441 Fuzz testing: Parser16
13461 Fuzz testing: Parser21
13464 ! irc://{{ftp://a" onmouseover="alert('hello world');"
13469 <th> <a rel="nofollow" class="external free" href="irc://{{ftp://a">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
13479 Fuzz testing: Parser22
13481 http://===r:::https://b
13485 <p><a rel="nofollow" class="external free" href="http://===r:::https://b">http://===r:::https://b</a>
13493 # Known to produce bad XML for now
13495 Fuzz testing: Parser24
13502 | {{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}} >
13503 <br style="onmouseover='alert(document.cookie);' " />
13505 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
13510 <u class="|">}}}} >
13511 <br style="onmouseover='alert(document.cookie);'" />
13513 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
13522 # Note: the current result listed for this is not what the original one was,
13523 # but the original bug was JavaScript injection, which is fixed in any case.
13524 # It's not clear that the original result listed was any more correct than the
13525 # current one. Original result:
13528 # <li class="||">
13529 # }}}blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
13531 Fuzz testing: Parser25 (bug 6055)
13537 }}}blah" onmouseover="alert('hello world');" align="left"'''MOVE MOUSE CURSOR OVER HERE
13539 <p><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
13544 Fuzz testing: URL adjacent extension (with space, clean)
13547 http://example.com <nowiki>junk</nowiki>
13549 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> junk
13554 Fuzz testing: URL adjacent extension (no space, dirty; nowiki)
13557 http://example.com<nowiki>junk</nowiki>
13559 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>junk
13564 Fuzz testing: URL adjacent extension (no space, dirty; pre)
13567 http://example.com<pre>junk</pre>
13569 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><pre>junk</pre>
13574 Fuzz testing: image with bogus manual thumbnail
13576 [[Image:foobar.jpg|thumbnail= ]]
13578 <div class="thumb tright"><div class="thumbinner" style="width:182px;">Error creating thumbnail: <div class="thumbcaption"></div></div></div>
13581 <meta typeof="mw:Placeholder" data-parsoid='{"src":"[[Image:foobar.jpg|thumbnail= ]]","optList":[{"ck":"manualthumb","ak":"thumbnail= "}],"dsr":[0,32,null,null]}'/>
13585 Fuzz testing: encoded newline in generated HTML replacements (bug 6577)
13587 <pre dir=" "></pre>
13589 <pre dir=" "></pre>
13594 Parsing optional HTML elements (Bug 6171)
13599 <td> Some tabular data</td>
13600 <td> More tabular data ...
13601 <td> And yet som tabular data</td>
13607 <td> Some tabular data</td>
13608 <td> More tabular data ...
13609 </td><td> And yet som tabular data</td>
13616 Correct handling of <td>, <tr> (Bug 6171)
13621 <td> Some tabular data</td>
13622 <td> More tabular data ...</td>
13623 <td> And yet som tabular data</td>
13629 <td> Some tabular data</td>
13630 <td> More tabular data ...</td>
13631 <td> And yet som tabular data</td>
13639 Parsing crashing regression (fr:JavaScript)
13643 <p></body></x>
13648 Inline wiki vs wiki block nesting
13654 <p><b>Bold paragraph</b>
13655 </p><p>New wiki paragraph
13660 Inline HTML vs wiki block nesting
13668 <p><b>Bold paragraph</b>
13669 </p><p>New wiki paragraph
13673 # Original result was this:
13674 # <p><b>bold</b><b>bold<i>bolditalics</i></b>
13676 # While that might be marginally more intuitive, maybe, the six-apostrophe
13677 # construct is clearly pathological and the result stated here (which is what
13678 # the parser actually does) is about as reasonable as anything.
13680 Mixing markup for italics and bold
13683 '''bold''''''bold''bolditalics'''''
13685 <p>'<i>bold'</i><b>bold<i>bolditalics</i></b>
13693 Article for special page transclusion test
13697 Special page transclusion
13700 {{Special:Prefixindex/Xyzzyx}}
13702 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
13707 Special page transclusion twice (bug 5021)
13710 {{Special:Prefixindex/Xyzzyx}}
13711 {{Special:Prefixindex/Xyzzyx}}
13713 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
13714 <table class="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
13719 Transclusion of default MediaWiki message
13721 {{MediaWiki:Mainpage}}
13728 Transclusion of nonexistent MediaWiki message
13730 {{MediaWiki:Mainpagexxx}}
13732 <p><a href="/index.php?title=MediaWiki:Mainpagexxx&action=edit&redlink=1" class="new" title="MediaWiki:Mainpagexxx (page does not exist)">MediaWiki:Mainpagexxx</a>
13737 Transclusion of MediaWiki message with underscore
13739 {{MediaWiki:history_short}}
13746 Transclusion of MediaWiki message with space
13748 {{MediaWiki:history short}}
13755 Invalid header with following text
13765 Section extraction test (section 0)
13785 Section extraction test (section 1)
13807 Section extraction test (section 2)
13828 Section extraction test (section 3)
13848 Section extraction test (section 4)
13872 Section extraction test (section 5)
13892 Section extraction test (section 6)
13913 Section extraction test (section 7)
13933 Section extraction test (section 8)
13953 Section extraction test (section 9)
13974 Section extraction test (section 10)
13994 Section extraction test (nonexistent section 11)
14013 Section extraction test with bogus heading (section 1)
14018 ==bogus== not a legal section
14022 ==bogus== not a legal section
14026 Section extraction test with bogus heading (section 2)
14031 ==bogus== not a legal section
14038 Section extraction test with comment after heading (section 1)
14050 Section extraction test with comment after heading (section 2)
14062 Section extraction test with bogus <nowiki> heading (section 1)
14067 ==bogus== <nowiki>not a legal section</nowiki>
14071 ==bogus== <nowiki>not a legal section</nowiki>
14075 Section extraction test with bogus <nowiki> heading (section 2)
14080 ==bogus== <nowiki>not a legal section</nowiki>
14087 # Formerly testing for bug 2587, now resolved by the use of unmarked sections
14088 # instead of respecting commented sections
14090 Section extraction prefixed by comment (section 1)
14101 Section extraction prefixed by comment (section 2)
14112 # Formerly testing for bug 2607, now resolved by the use of unmarked sections
14113 # instead of respecting HTML-style headings
14115 Section extraction, mixed wiki and html (section 1)
14131 Section extraction, mixed wiki and html (section 2)
14147 # Formerly testing for bug 3342
14149 Section extraction, heading surrounded by <noinclude>
14153 <noinclude>==unmarked==</noinclude>
14159 # Test behavior of bug 19910
14161 Sectiion with all-equals
14166 The line above must have a trailing space
14169 But just in case it doesn't...
14173 But just in case it doesn't...
14177 Section replacement test (section 0)
14208 Section replacement test (section 1)
14237 Section replacement test (section 2)
14267 Section replacement test (section 3)
14298 Section replacement test (section 4)
14325 Section replacement test (section 5)
14356 Section replacement test (section 6)
14386 Section replacement test (section 7)
14417 Section replacement test (section 8)
14448 Section replacement test (section 9)
14477 Section replacement test (section 10)
14507 Section replacement test with initial whitespace (bug 13728)
14511 Preformatted initial line
14515 Preformatted initial line
14522 Section extraction, heading followed by pre with 20 spaces (bug 6398)
14534 Section extraction, heading followed by pre with 19 spaces (bug 6398 sanity check)
14547 Section extraction, <pre> around bogus header (bug 10309)
14564 Section replacement, <pre> around bogus header (bug 10309)
14566 noxml replace=2,"xxx"
14587 Handling of 
 in URLs
14591 <ul><li><ul><li> <a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
14594 <ul><li><ul><li> <a rel="mw:ExtLink" href="irc://
14596 a</a></li></ul></li></ul>
14600 Handling of %0A in URLs
14604 <ul><li><ul><li> <a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
14607 <ul><li><ul><li> <a rel="mw:ExtLink" href="irc://%0Aa">irc://%0Aa</a></li></ul></li></ul>
14611 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
14613 5 quotes, code coverage +1 line
14620 <p><b><i></i></b></p>
14623 # same html as previous, but wikitext adjusted to match parsoid html2wt
14624 # note that wt2html and html2html will put the <i> before the <b>
14626 5 quotes, code coverage +1 line w/ nowiki (1)
14628 parsoid=wt2wt,html2wt
14630 '''''<nowiki/>'''''
14635 <p><b><i></i></b></p>
14638 # same as previous, just swapping the <i> and <b>
14640 5 quotes, code coverage +1 line w/ nowiki (2)
14642 '''''<nowiki/>'''''
14647 <p><i><b></b></i></p>
14651 Special:Search page linking.
14655 <p><a href="/wiki/Special:Search" title="Special:Search">Special:Search</a>
14662 title=[[Parser test]]
14667 * {{FULLPAGENAMEE}}
14669 * {{BASEPAGENAMEE}}
14673 * {{ROOTPAGENAMEE}}
14675 * {{TALKPAGENAMEE}}
14676 * {{SUBJECTPAGENAME}}
14677 * {{SUBJECTPAGENAMEE}}
14680 * {{NAMESPACENUMBER}}
14684 * {{SUBJECTSPACEE}}
14685 * {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}
14687 <ul><li> Parser test</li>
14688 <li> Parser_test</li>
14689 <li> Parser test</li>
14690 <li> Parser_test</li>
14691 <li> Parser test</li>
14692 <li> Parser_test</li>
14693 <li> Parser test</li>
14694 <li> Parser_test</li>
14695 <li> Parser test</li>
14696 <li> Parser_test</li>
14697 <li> Talk:Parser test</li>
14698 <li> Talk:Parser_test</li>
14699 <li> Parser test</li>
14700 <li> Parser_test</li>
14708 <li> <a href="/index.php?title=Template:Dynamic&action=edit&redlink=1" class="new" title="Template:Dynamic (page does not exist)">Template:Dynamic</a></li></ul>
14711 ### Note: Above tests excludes the "{{NUMBEROFADMINS}}" magic word because it generates a MySQL error when included.
14721 image4 |300px| centre
14722 image5.svg| http://///////
14727 <ul class="gallery mw-gallery-traditional">
14728 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14729 <div class="thumb" style="height: 150px;">Image1.png</div>
14730 <div class="gallerytext">
14733 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14734 <div class="thumb" style="height: 150px;">Image2.gif</div>
14735 <div class="gallerytext">
14740 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14741 <div class="thumb" style="height: 150px;">Image3</div>
14742 <div class="gallerytext">
14745 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14746 <div class="thumb" style="height: 150px;">Image4</div>
14747 <div class="gallerytext">
14752 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14753 <div class="thumb" style="height: 150px;">Image5.svg</div>
14754 <div class="gallerytext">
14755 <p><a rel="nofollow" class="external free" href="http://///////">http://///////</a>
14759 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14760 <div class="thumb" style="height: 150px;">* image6</div>
14761 <div class="gallerytext">
14769 Gallery (with options)
14771 <gallery widths='70px' heights='40px' perrow='2' caption='Foo [[Main Page]]' >
14772 File:Nonexistant.jpg|caption
14773 File:Nonexistant.jpg
14774 image:foobar.jpg|some '''caption''' [[Main Page]]
14776 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
14779 <ul class="gallery mw-gallery-traditional" style="max-width: 226px;_width: 226px;">
14780 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
14781 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
14782 <div class="thumb" style="height: 70px;">Nonexistant.jpg</div>
14783 <div class="gallerytext">
14788 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
14789 <div class="thumb" style="height: 70px;">Nonexistant.jpg</div>
14790 <div class="gallerytext">
14793 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
14794 <div class="thumb" style="width: 100px;"><div style="margin:31px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" width="70" height="8" /></a></div></div>
14795 <div class="gallerytext">
14796 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
14800 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
14801 <div class="thumb" style="width: 100px;"><div style="margin:31px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" width="70" height="8" /></a></div></div>
14802 <div class="gallerytext">
14805 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
14806 <div class="thumb" style="width: 100px;"><div style="margin:31px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="This is a foo-bar." src="http://example.com/images/thumb/3/3a/Foobar.jpg/70px-Foobar.jpg" width="70" height="8" /></a></div></div>
14807 <div class="gallerytext">
14817 Gallery with wikitext inside caption
14820 File:foobar.jpg|[[File:foobar.jpg|20px|desc|alt=inneralt]]|alt=galleryalt
14821 File:foobar.jpg|{{Test|unamedParam|alt=param}}|alt=galleryalt
14824 <ul class="gallery mw-gallery-traditional">
14825 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14826 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
14827 <div class="gallerytext">
14828 <p><a href="/wiki/File:Foobar.jpg" class="image" title="desc"><img alt="inneralt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/20px-Foobar.jpg" width="20" height="2" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/30px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/40px-Foobar.jpg 2x" /></a>
14832 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14833 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
14834 <div class="gallerytext">
14835 <p>This is a test template
14844 gallery (with showfilename option)
14846 <gallery showfilename>
14847 File:Nonexistant.jpg|caption
14848 File:Nonexistant.jpg
14849 image:foobar.jpg|some '''caption''' [[Main Page]]
14853 <ul class="gallery mw-gallery-traditional">
14854 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14855 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
14856 <div class="gallerytext">
14857 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
14862 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14863 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
14864 <div class="gallerytext">
14865 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
14869 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14870 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
14871 <div class="gallerytext">
14872 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
14873 some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
14877 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14878 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
14879 <div class="gallerytext">
14880 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
14889 Gallery (with namespace-less filenames)
14892 File:Nonexistant.jpg
14898 <ul class="gallery mw-gallery-traditional">
14899 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14900 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
14901 <div class="gallerytext">
14904 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14905 <div class="thumb" style="height: 150px;">Nonexistant.jpg</div>
14906 <div class="gallerytext">
14909 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14910 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
14911 <div class="gallerytext">
14914 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
14915 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
14916 <div class="gallerytext">
14924 HTML Hex character encoding (spells the word "JavaScript")
14926 parsoid=wt2html,wt2wt,html2html
14928 JavaScript
14930 <p>JavaScript
14933 <p><span typeof="mw:Entity">J</span><span typeof="mw:Entity">a</span><span typeof="mw:Entity">v</span><span typeof="mw:Entity">a</span><span typeof="mw:Entity">S</span><span typeof="mw:Entity">c</span><span typeof="mw:Entity">r</span><span typeof="mw:Entity">i</span><span typeof="mw:Entity">p</span><span typeof="mw:Entity">t</span></p>
14937 HTML Hex character encoding bogus encoding (bug 26437 regression check)
14941 <p>&#xsee;&#XSEE;
14944 <p>&#xsee;&#XSEE;</p>
14948 HTML Hex character encoding mixed case
14950 parsoid=wt2html,wt2wt,html2html
14957 <p><span typeof="mw:Entity">î</span><span typeof="mw:Entity">î</span></p>
14961 __FORCETOC__ override
14973 ISBN 978-0-1234-56 789
14975 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789
14980 ISBN followed by 5 spaces
14991 ISBN ISBN 1234567890
14993 <p>ISBN <a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
15002 <p><a href="/wiki/Special:BookSources/346204561X" class="internal mw-magiclink-isbn">ISBN 3-462-04561-X</a>
15007 ISBN with empty prefix (parsoid test)
15011 <p><a href="Special:BookSources/1234567890" rel="mw:ExtLink">ISBN 1234567890</a></p>
15015 Bug 22905: <abbr> followed by ISBN followed by </a>
15017 <abbr>(fr)</abbr> ISBN 2753300917 [http://www.example.com example.com]
15019 <p><abbr>(fr)</abbr> <a href="/wiki/Special:BookSources/2753300917" class="internal mw-magiclink-isbn">ISBN 2753300917</a> <a rel="nofollow" class="external text" href="http://www.example.com">example.com</a>
15028 <p>RFC <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a>
15033 Double RFC with a wiki link
15037 <p>RFC <a href="/index.php?title=RFC_1234&action=edit&redlink=1" class="new" title="RFC 1234 (page does not exist)">RFC 1234</a>
15046 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987
15051 Centre-aligned image
15053 [[Image:foobar.jpg|centre]]
15055 <div class="center"><div class="floatnone"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div></div>
15062 [[Image:foobar.jpg|none]]
15064 <div class="floatnone"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></div>
15069 Width + Height sized image (using px) (height is ignored)
15071 [[Image:foobar.jpg|640x480px]]
15073 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/960px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/1280px-Foobar.jpg 2x" /></a>
15078 Width-sized image (using px, no following whitespace)
15080 [[Image:foobar.jpg|640px]]
15082 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/960px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/1280px-Foobar.jpg 2x" /></a>
15087 Width-sized image (using px, with following whitespace - test regression from r39467)
15089 [[Image:foobar.jpg|640px ]]
15091 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/960px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/1280px-Foobar.jpg 2x" /></a>
15096 Width-sized image (using px, with preceding whitespace - test regression from r39467)
15098 [[Image:foobar.jpg| 640px]]
15100 <p><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/640px-Foobar.jpg" width="640" height="73" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/960px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/1280px-Foobar.jpg 2x" /></a>
15105 Image with page parameter
15109 [[File:LoremIpsum.djvu|page=2]]
15111 <p><a href="/index.php?title=File:LoremIpsum.djvu&page=2" class="image"><img alt="LoremIpsum.djvu" src="http://example.com/images/thumb/5/5f/LoremIpsum.djvu/page2-2480px-LoremIpsum.djvu.jpg" width="2480" height="3508" srcset="http://example.com/images/thumb/5/5f/LoremIpsum.djvu/page2-3720px-LoremIpsum.djvu.jpg 1.5x, http://example.com/images/thumb/5/5f/LoremIpsum.djvu/page2-4960px-LoremIpsum.djvu.jpg 2x" /></a>
15116 Another italics / bold test
15124 # Note the results may be incorrect, as parserTest output included this:
15125 # XML error: Mismatched tag at byte 6120:
15126 # ...<dd> </dt></dl> </dd...
15157 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
15159 Images with the "|" character in the comment
15161 [[File:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]]
15163 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/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 rel="nofollow" class="external text" href="http://test/?param1=%7Cleft%7C&param2=%7Cx">external</a> URL</div></div></div>
15166 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="25" width="220"/></a><figcaption>An <a rel="mw:ExtLink" href="http://test/?param1=|left|&param2=|x">external</a> URL</figcaption></figure>
15170 [Before] HTML without raw HTML enabled ($wgRawHtml==false)
15172 <html><script>alert(1);</script></html>
15174 <p><html><script>alert(1);</script></html>
15179 HTML with raw HTML ($wgRawHtml==true)
15183 <html><script>alert(1);</script></html>
15185 <p><script>alert(1);</script>
15190 Parents of subpages, one level up
15192 subpage title=[[Subpage test/L1/L2/L3]]
15196 <p><a href="/index.php?title=Subpage_test/L1/L2&action=edit&redlink=1" class="new" title="Subpage test/L1/L2 (page does not exist)">L2</a>
15202 Parents of subpages, one level up, not named
15204 subpage title=[[Subpage test/L1/L2/L3]]
15208 <p><a href="/index.php?title=Subpage_test/L1/L2&action=edit&redlink=1" class="new" title="Subpage test/L1/L2 (page does not exist)">Subpage test/L1/L2</a>
15215 Parents of subpages, two levels up
15217 subpage title=[[Subpage test/L1/L2/L3]]
15223 <p><a href="/index.php?title=Subpage_test/L1&action=edit&redlink=1" class="new" title="Subpage test/L1 (page does not exist)">L1</a>2
15224 </p><p><a href="/index.php?title=Subpage_test/L1&action=edit&redlink=1" class="new" title="Subpage test/L1 (page does not exist)">L1l</a>
15229 Parents of subpages, two levels up, without trailing slash or name.
15231 subpage title=[[Subpage test/L1/L2/L3]]
15240 Parents of subpages, two levels up, with lots of extra trailing slashes.
15242 subpage title=[[Subpage test/L1/L2/L3]]
15246 <p><a href="/index.php?title=Subpage_test/L1////&action=edit&redlink=1" class="new" title="Subpage test/L1//// (page does not exist)">///</a>
15251 Subpage test/L1/L2/L3Sibling
15257 Transclusion of a sibling page (one level up)
15259 subpage title=[[Subpage test/L1/L2/L3]]
15268 Transclusion of a child page
15270 subpage title=[[Subpage test/L1/L2]]
15279 Non-transclusion because of too many up levels
15281 subpage title=[[Subpage test/L1/L2/L3]]
15283 {{../../../../More than parent}}
15285 <p>{{../../../../More than parent}}
15290 Definition list code coverage
15296 <dl><dt> title  </dt>
15298 <dt> title </dt>
15306 Don't fall for the self-closing div
15308 <div>hello world</div/>
15310 <div>hello world</div>
15319 <p>[[:Template:Msg]]
15328 <p><a href="/index.php?title=Template:QUERTY&action=edit&redlink=1" class="new" title="Template:QUERTY (page does not exist)">Template:QUERTY</a>
15332 # This isn't needed for XHTML conformance, but would be handy as a fallback security measure
15334 Always escape literal '>' in output, not just after '<'
15348 <p>This is a test template
15349 This is a test template
15361 Inclusion of !userCanEdit() content
15365 <h2><span class="mw-headline" id="header">header</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=MediaWiki:Fake&action=edit&section=T-1" title="MediaWiki:Fake">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15371 Out-of-order TOC heading levels
15380 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15382 <li class="toclevel-1 tocsection-1"><a href="#2"><span class="tocnumber">1</span> <span class="toctext">2</span></a>
15384 <li class="toclevel-2 tocsection-2"><a href="#6"><span class="tocnumber">1.1</span> <span class="toctext">6</span></a></li>
15385 <li class="toclevel-2 tocsection-3"><a href="#3"><span class="tocnumber">1.2</span> <span class="toctext">3</span></a></li>
15388 <li class="toclevel-1 tocsection-4"><a href="#1"><span class="tocnumber">2</span> <span class="toctext">1</span></a>
15390 <li class="toclevel-2 tocsection-5"><a href="#5"><span class="tocnumber">2.1</span> <span class="toctext">5</span></a></li>
15391 <li class="toclevel-2 tocsection-6"><a href="#2_2"><span class="tocnumber">2.2</span> <span class="toctext">2</span></a></li>
15397 <h2><span class="mw-headline" id="2">2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15398 <h6><span class="mw-headline" id="6">6</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: 6">edit</a><span class="mw-editsection-bracket">]</span></span></h6>
15399 <h3><span class="mw-headline" id="3">3</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: 3">edit</a><span class="mw-editsection-bracket">]</span></span></h3>
15400 <h1><span class="mw-headline" id="1">1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: 1">edit</a><span class="mw-editsection-bracket">]</span></span></h1>
15401 <h5><span class="mw-headline" id="5">5</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: 5">edit</a><span class="mw-editsection-bracket">]</span></span></h5>
15402 <h2><span class="mw-headline" id="2_2">2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
15408 ISBN with a dummy number
15418 ISBN with space-delimited number
15422 <p><a href="/wiki/Special:BookSources/9290170328" class="internal mw-magiclink-isbn">ISBN 92 9017 032 8</a>
15428 ISBN with multiple spaces, no number
15447 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
15448 </p><p>ISBN 12345678901
15454 ISBN with trailing year (bug 8110)
15456 ISBN 1-234-56789-0 - 2006
15458 ISBN 1 234 56789 0 - 2006
15460 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1-234-56789-0</a> - 2006
15461 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1 234 56789 0</a> - 2006
15469 {{anchorencode:foo bar©#%n}}
15471 <p>foo_bar.C2.A9.23.25n
15476 anchorencode trims spaces
15478 {{anchorencode: __pretty__please__}}
15485 anchorencode deals with links
15487 {{anchorencode: [[hello|world]] [[hi]]}}
15494 anchorencode deals with templates
15496 {{anchorencode: {{Foo}} }}
15503 anchorencode encodes like the TOC generator: (bug 18431)
15505 === _ +:.3A%3A&&]] ===
15506 {{anchorencode: _ +:.3A%3A&&]] }}
15509 <h3><span class="mw-headline" id=".2B:.3A.253A.26.26.5D.5D">_ +:.3A%3A&&]]</span></h3>
15510 <p>.2B:.3A.253A.26.26.5D.5D
15515 Bug 6200: blockquotes and paragraph formatting
15536 Bug 8293: Use of center tag ruins paragraph formatting
15557 Parsing of overlapping (improperly nested) inline html tags
15559 <span><s>x</span></s>
15561 <p><span><s>x</span></s></span>
15564 <p><span><s>x</s></span>
15569 ### Language variants related tests
15572 Self-link in language variants
15574 title=[[Dunav]] language=sr
15576 Both [[Dunav]] and [[Дунав]] are names for this river.
15578 <p>Both <strong class="selflink">Dunav</strong> and <strong class="selflink">Дунав</strong> are names for this river.
15589 Link to another existing title shouldn't be parsed as self-link even if it's a variant of this title
15591 title=[[Duna]] language=sr
15593 [[Дуна]] is not a self-link while [[Duna]] and [[Dуна]] are still self-links.
15595 <p><a href="/wiki/%D0%94%D1%83%D0%BD%D0%B0" title="Дуна">Дуна</a> is not a self-link while <strong class="selflink">Duna</strong> and <strong class="selflink">Dуна</strong> are still self-links.
15600 Link to a section of a variant of this title shouldn't be parsed as self-link
15602 title=[[Duna]] language=sr
15604 [[Dуна]] is a self-link while [[Dunа#Foo]] and [[Dуна#Foo]] are not self-links.
15606 <p><strong class="selflink">Dуна</strong> is a self-link while <a href="/wiki/%D0%94%D1%83%D0%BD%D0%B0" title="Дуна">Dunа#Foo</a> and <a href="/wiki/%D0%94%D1%83%D0%BD%D0%B0" title="Дуна">Dуна#Foo</a> are not self-links.
15611 Link to pages in language variants
15615 Main Page can be written as [[Маин Паге]]
15617 <p>Main Page can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>
15623 Multiple links to pages in language variants
15627 [[Main Page]] can be written as [[Маин Паге]] same as [[Маин Паге]].
15629 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a> can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a> same as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>.
15635 Simple template in language variants
15641 <p>This is a test template
15647 Template with explicit namespace in language variants
15653 <p>This is a test template
15659 Basic test for template parameter in language variants
15663 {{парамтест|param=foo}}
15665 <p>This is a test template with parameter foo
15671 Simple category in language variants
15675 [[Category:МедиаWики Усер'с Гуиде]]
15677 <a href="/wiki/%D0%9A%D0%B0%D1%82%D0%B5%D0%B3%D0%BE%D1%80%D0%B8%D1%98%D0%B0:MediaWiki_User%27s_Guide" title="Категорија:MediaWiki User's Guide">MediaWiki User's Guide</a>
15694 Don't convert blue categorylinks to another variant (bug 33210)
15698 [[A]][[Category:分类]]
15700 <a href="/wiki/Category:%E5%88%86%E7%B1%BB" title="Category:分类">分类</a>
15705 Stripping -{}- tags (language variants)
15709 Latin proverb: -{Ne nuntium necare}-
15711 <p>Latin proverb: Ne nuntium necare
15717 Prevent conversion with -{}- tags (language variants)
15719 language=sr variant=sr-ec
15721 Latinski: -{Ne nuntium necare}-
15723 <p>Латински: Ne nuntium necare
15729 Prevent conversion of text with -{}- tags (language variants)
15731 language=sr variant=sr-ec
15733 Latinski: -{Ne nuntium necare}-
15735 <p>Латински: Ne nuntium necare
15741 Prevent conversion of links with -{}- tags (language variants)
15743 language=sr variant=sr-ec
15747 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
15753 -{}- tags within headlines (within html for parserConvert())
15755 language=sr variant=sr-ec
15759 <h2><span class="mw-headline" id="-.7BNaslov.7D-">Naslov</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Уредите одељак „Naslov“">уреди</a><span class="mw-editsection-bracket">]</span></span></h2>
15765 Explicit definition of language variant alternatives
15767 language=zh variant=zh-tw
15769 -{zh:China;zh-tw:Taiwan}-, not China
15771 <p>Taiwan, not China
15777 Conversion around HTML tags
15779 language=sr variant=sr-ec
15781 -{H|span=>sr-ec:script;title=>sr-ec:src;}-
15782 <span title="La-{sr-el:L;sr-ec:C;}-tin">ski</span>
15785 <span title="ЛаCтин">ски</span>
15791 Explicit session-wise language variant mapping (A flag and - flag)
15793 language=zh variant=zh-tw
15795 Taiwan is not China.
15796 But -{A|zh:China;zh-tw:Taiwan}- is China,
15797 (This-{-|zh:China;zh-tw:Taiwan}- should be stripped!)
15798 and -{China}- is China.
15800 <p>Taiwan is not China.
15801 But Taiwan is Taiwan,
15802 (This should be stripped!)
15803 and China is China.
15808 Explicit session-wise language variant mapping (H flag for hide)
15810 language=zh variant=zh-tw
15812 (This-{H|zh:China;zh-tw:Taiwan}- should be stripped!)
15815 <p>(This should be stripped!)
15821 Adding explicit conversion rule for title (T flag)
15823 language=zh variant=zh-tw showtitle
15825 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
15828 <p>Should be stripped!
15833 Testing that changing the language variant here in the tests actually works
15835 language=zh variant=zh showtitle
15837 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
15840 <p>Should be stripped!
15845 Recursive conversion of alt and title attrs shouldn't clear converter state
15847 language=zh variant=zh-cn showtitle
15849 -{H|zh-cn:Exclamation;zh-tw:exclamation;}-
15850 Should be stripped-{T|zh-cn:China;zh-tw:Taiwan}-<span title="exclamation">!</span>
15854 Should be stripped<span title="Exclamation">!</span>
15859 Bug 24072: more test on conversion rule for title
15861 language=zh variant=zh-tw showtitle
15863 This should be stripped-{T|zh:China;zh-tw:Taiwan}-!
15864 This won't take interferes with the title rule-{H|zh:Beijing;zh-tw:Taipei}-.
15867 <p>This should be stripped!
15868 This won't take interferes with the title rule.
15873 Partly disable title conversion if variant == main language code
15875 language=zh variant=zh title=[[ZH]] showtitle
15877 -{T|zh-cn:CN;zh-tw:TW}-
15885 Partly disable title conversion if variant == main language code, more
15887 language=zh variant=zh title=[[ZH]] showtitle
15897 Raw output of variant escape tags (R flag)
15899 language=zh variant=zh-tw
15901 Raw: -{R|zh:China;zh-tw:Taiwan}-
15903 <p>Raw: zh:China;zh-tw:Taiwan
15908 Nested using of manual convert syntax
15910 language=zh variant=zh-hk
15912 Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiwan;zh-hk:H-{ong}- K-{}-ong;}-;}-!
15914 <p>Nested: Hello Hong Kong!
15919 Proper conversion of text in external links
15921 language=sr variant=sr-ec
15923 http://www.google.com
15924 gopher://www.google.com
15925 [http://www.google.com http://www.google.com]
15926 [gopher://www.google.com gopher://www.google.com]
15927 [https://www.google.com irc://www.google.com]
15928 [ftp://www.google.com www.google.com/ftp://dir]
15929 [//www.google.com www.google.com]
15931 <p><a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
15932 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
15933 <a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
15934 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
15935 <a rel="nofollow" class="external text" href="https://www.google.com">irc://www.google.com</a>
15936 <a rel="nofollow" class="external text" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
15937 <a rel="nofollow" class="external text" href="//www.google.com">www.гоогле.цом</a>
15942 Do not convert roman numbers to language variants
15944 language=sr variant=sr-ec
15948 <p>Фридрих IV је цар.
15953 Unclosed language converter markup "-{"
15964 Don't convert raw rule "-{R|=>}-" to "=>"
15975 Don't break link parsing if language converter markup is in the caption.
15977 language=sr variant=sr-ec
15979 [[Main Page|-{R|main page}-]]
15981 <p><a href="/wiki/Main_Page" title="Маин Паге">main page</a>
15985 # This test is currently broken in the PHP parser (bug 52661)
15987 Don't break image parsing if language converter markup is in the caption.
15992 [[File:Foobar.jpg|-{R|caption}-]]
15994 <p><a href="/wiki/File:Foobar.jpg" class="image" title="caption"><img alt="caption" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
15998 # This test is currently broken in the PHP parser (bug 52661)
16000 Don't break list handling if language converter markup is in the item.
16002 language=zh variant=zh-cn
16005 ;-{zh-cn:AAA;zh-tw:BBB}-
16012 # This test is currently broken in the PHP parser (bug 52661)
16014 Don't break table handling if language converter markup is in the cell.
16016 language=sr variant=sr-ec
16033 Bug 529: Uncovered bullet
16042 # Plain MediaWiki does not remove empty lists, but tidy actually does.
16043 # Templates in Wikipedia rely on this behavior, as tidy has always been
16044 # enabled there. These tests are normally run *without* tidy, so specify the
16045 # full output here.
16046 # To test realistic parsing behavior, apply a tidy-like transformation to both
16047 # the expected output and your parser's output.
16049 Bug 529: Uncovered bullet leaving empty list, normally removed by tidy
16051 ******* Foo {{bullet}}
16053 <ul><li><ul><li><ul><li><ul><li><ul><li><ul><li><ul><li> Foo </li></ul></li></ul></li></ul></li></ul></li></ul></li></ul></li>
16059 Bug 529: Uncovered table already at line-start
16082 Bug 529: Uncovered bullet in parser function result
16084 * Foo {{lc:{{bullet}} }}
16092 Bug 5678: Double-parsed template argument
16094 {{lc:{{{1}}}|hello}}
16101 Bug 5678: Double-parsed template invocation
16103 {{lc:{{paramtest {{!}} param = hello }} }}
16105 <p>{{paramtest | param = hello }}
16110 Case insensitivity of parser functions for non-ASCII characters (bug 8143)
16113 title=[[Main Page]]
16115 {{PRVNÍVELKÉ:ěščř}}
16116 {{prvnívelké:ěščř}}
16136 Morwen/13: Unclosed link followed by heading
16143 <h2><span class="mw-headline" id="heading">heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: heading">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
16148 HHP2.1: Heuristics for headings in preprocessor parenthetical structures
16155 <h1><span class="mw-headline" id="heading">heading</span></h1>
16160 HHP2.2: Heuristics for headings in preprocessor parenthetical structures
16167 <h2><span class="mw-headline" id="heading">heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: heading">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
16182 Paragraphs inside divs (no extra line breaks)
16194 Paragraphs inside divs (extra line break on open)
16209 Paragraphs inside divs (extra line break on close)
16224 Paragraphs inside divs (extra line break on open and close)
16241 Nesting tags, paragraphs on lines which begin with <div>
16245 <div></div><strong>A
16254 # Bug 6200: <blockquote> should behave like <div> with respect to line breaks
16256 Bug 6200: paragraphs inside blockquotes (no extra line breaks)
16258 <blockquote>Line one
16260 Line two</blockquote>
16262 <blockquote>Line one
16263 Line two</blockquote>
16268 Bug 6200: paragraphs inside blockquotes (extra line break on open)
16273 Line two</blockquote>
16278 Line two</blockquote>
16283 Bug 6200: paragraphs inside blockquotes (extra line break on close)
16285 <blockquote>Line one
16290 <blockquote>Line one
16298 Bug 6200: paragraphs inside blockquotes (extra line break on open and close)
16315 Paragraphs inside blockquotes/divs (no extra line breaks)
16317 <blockquote><div>Line one
16319 Line two</div></blockquote>
16321 <blockquote><div>Line one
16322 Line two</div></blockquote>
16327 Paragraphs inside blockquotes/divs (extra line break on open)
16332 Line two</div></blockquote>
16337 Line two</div></blockquote>
16342 Paragraphs inside blockquotes/divs (extra line break on close)
16344 <blockquote><div>Line one
16347 </div></blockquote>
16349 <blockquote><div>Line one
16352 </div></blockquote>
16357 Paragraphs inside blockquotes/divs (extra line break on open and close)
16363 </div></blockquote>
16369 </div></blockquote>
16374 Interwiki links trounced by replaceExternalLinks after early LinkHolderArray expansion
16376 wgLinkHolderBatchSize=0
16382 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?1" class="extiw" title="meatball:1">meatball:1</a>
16383 <a href="http://www.usemod.com/cgi-bin/mb.pl?2" class="extiw" title="meatball:2">meatball:2</a>
16384 <a href="http://www.usemod.com/cgi-bin/mb.pl?3" class="extiw" title="meatball:3">meatball:3</a>
16389 Free external link invading image caption
16391 [[Image:Foobar.jpg|thumb|http://x|hello]]
16393 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/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" srcset="http://example.com/images/thumb/3/3a/Foobar.jpg/270px-Foobar.jpg 1.5x, http://example.com/images/thumb/3/3a/Foobar.jpg/360px-Foobar.jpg 2x" /></a> <div class="thumbcaption"><div class="magnify"><a href="/wiki/File:Foobar.jpg" class="internal" title="Enlarge"><img src="/skins/common/images/magnify-clip.png" width="15" height="11" alt="" /></a></div>hello</div></div></div>
16398 Bug 15196: localised external link numbers
16402 [http://en.wikipedia.org/]
16404 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/">[۱]</a>
16407 <p><a rel="mw:ExtLink" href="http://en.wikipedia.org/"></a></p>
16411 Multibyte character in padleft
16413 {{padleft:-Hello|7|Æ}}
16420 Multibyte character in padright
16422 {{padright:Hello-|7|Æ}}
16429 formatdate parser function
16431 {{#formatdate:2009-03-24}}
16433 <p><span class="mw-formatted-date" title="2009-03-24">2009-03-24</span>
16438 formatdate parser function, with default format
16440 {{#formatdate:2009-03-24|mdy}}
16442 <p><span class="mw-formatted-date" title="2009-03-24">March 24, 2009</span>
16447 Spacing of numbers in formatted dates
16449 {{#formatdate:January 15}}
16451 <p><span class="mw-formatted-date" title="01-15">January 15</span>
16456 formatdate parser function, with default format and on a page of which the content language is always English and different from the wiki content language
16458 language=nl title=[[MediaWiki:Common.css]]
16460 {{#formatdate:2009-03-24|dmy}}
16462 <p><span class="mw-formatted-date" title="2009-03-24">24 March 2009</span>
16475 Edit comment with link
16479 I like the [[Main Page]] a lot
16481 I like the <a href="/wiki/Main_Page" title="Main Page">Main Page</a> a lot
16485 Edit comment with link and link text
16489 I like the [[Main Page|best pages]] a lot
16491 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
16495 Edit comment with link and link text with suffix
16499 I like the [[Main Page|best page]]s a lot
16501 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
16505 Edit comment with section link (non-local, eg in history list)
16507 comment title=[[Main Page]]
16509 /* External links */ removed bogus entries
16511 <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
16515 Edit comment with section link and text before it (non-local, eg in history list)
16517 comment title=[[Main Page]]
16519 pre-comment text /* External links */ removed bogus entries
16521 pre-comment text <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
16525 Edit comment with section link (local, eg in diff view)
16527 comment local title=[[Main Page]]
16529 /* External links */ removed bogus entries
16531 <a href="#External_links">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
16535 Edit comment with subpage link (bug 14080)
16539 title=[[Subpage test]]
16541 Poked at a [[/subpage]] here...
16543 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a> here...
16547 Edit comment with subpage link and link text (bug 14080)
16551 title=[[Subpage test]]
16553 Poked at a [[/subpage|neat little page]] here...
16555 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">neat little page</a> here...
16559 Edit comment with bogus subpage link in non-subpage NS (bug 14080)
16562 title=[[Subpage test]]
16564 Poked at a [[/subpage]] here...
16566 Poked at a <a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a> here...
16570 Edit comment with bare anchor link (local, as on diff)
16574 title=[[Main Page]]
16578 <a href="#section">#section</a>
16582 Edit comment with bare anchor link (non-local, as on history)
16585 title=[[Main Page]]
16589 <a href="/wiki/Main_Page#section" title="Main Page">#section</a>
16593 Anchor starting with underscore
16597 <p><a href="#_ref">One</a>
16602 Id starting with underscore
16604 <div id="_ref"></div>
16606 <div id="_ref"></div>
16611 Space normalisation on autocomment (bug 22784)
16614 title=[[Main Page]]
16616 /* __hello__world__ */
16618 <a href="/wiki/Main_Page#hello_world" title="Main Page">→</a><span dir="auto"><span class="autocomment">__hello__world__</span></span>
16622 percent-encoding and + signs in comments (Bug 26410)
16626 [[ABC%33D% ++]] [[ABC%33D% ++|+%20]]
16628 <a href="/index.php?title=ABC3D%25_%2B%2B&action=edit&redlink=1" class="new" title="ABC3D% ++ (page does not exist)">ABC3D% ++</a> <a href="/index.php?title=ABC3D%25_%2B%2B&action=edit&redlink=1" class="new" title="ABC3D% ++ (page does not exist)">+%20</a>
16632 Bad images - basic functionality
16641 Bad images - bug 16039: text after bad image disappears
16655 Verify that displaytitle works (bug #22501) no displaytitle
16659 wgAllowDisplayTitle=true
16660 wgRestrictDisplayTitle=false
16662 this is not the the title
16665 <p>this is not the the title
16670 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=false
16675 wgAllowDisplayTitle=true
16676 wgRestrictDisplayTitle=false
16678 this is not the the title
16679 {{DISPLAYTITLE:whatever}}
16682 <p>this is not the the title
16687 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true mismatch
16692 wgAllowDisplayTitle=true
16693 wgRestrictDisplayTitle=true
16695 this is not the the title
16696 {{DISPLAYTITLE:whatever}}
16699 <p>this is not the the title
16704 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true matching
16709 wgAllowDisplayTitle=true
16710 wgRestrictDisplayTitle=true
16712 this is not the the title
16713 {{DISPLAYTITLE:screen}}
16716 <p>this is not the the title
16721 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false
16726 wgAllowDisplayTitle=false
16728 this is not the the title
16729 {{DISPLAYTITLE:screen}}
16732 <p>this is not the the title
16733 <a href="/index.php?title=Template:DISPLAYTITLE:screen&action=edit&redlink=1" class="new" title="Template:DISPLAYTITLE:screen (page does not exist)">Template:DISPLAYTITLE:screen</a>
16738 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false no DISPLAYTITLE
16743 wgAllowDisplayTitle=false
16745 this is not the the title
16748 <p>this is not the the title
16753 Verify that displaytitle handles inline CSS styles (bug 26547) - rejected value
16758 wgAllowDisplayTitle=true
16759 wgRestrictDisplayTitle=true
16761 this is not the the title
16762 {{DISPLAYTITLE:<span style="display: none;">s</span>creen}}
16764 <span style="/* attempt to bypass $wgRestrictDisplayTitle */">s</span>creen
16765 <p>this is not the the title
16770 Verify that displaytitle handles inline CSS styles (bug 26547) - accepted value
16775 wgAllowDisplayTitle=true
16776 wgRestrictDisplayTitle=true
16778 this is not the the title
16779 {{DISPLAYTITLE:<span style="color: red;">s</span>creen}}
16781 <span style="color: red;">s</span>creen
16782 <p>this is not the the title
16787 preload: check <noinclude> and <includeonly>
16791 Hello <noinclude>cruel</noinclude><includeonly>kind</includeonly> world.
16797 preload: check <onlyinclude>
16801 Goodbye <onlyinclude>Hello world</onlyinclude>
16807 preload: can pass tags through if we want to
16811 <includeonly><</includeonly>includeonly>Hello world<includeonly><</includeonly>/includeonly>
16813 <includeonly>Hello world</includeonly>
16817 preload: check that it doesn't try to do tricks
16821 * <!-- Hello --> ''{{world}}'' {{<includeonly>subst:</includeonly>How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
16823 * <!-- Hello --> ''{{world}}'' {{subst:How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
16827 Play a bit with r67090 and bug 3158
16831 <div style="width:50% !important"> </div>
16832 <div style="width:50% !important"> </div>
16833 <div style="width:50% !important"> </div>
16834 <div style="border : solid;"> </div>
16836 <div style="width:50% !important"> </div>
16837 <div style="width:50% !important"> </div>
16838 <div style="width:50% !important"> </div>
16839 <div style="border : solid;"> </div>
16844 HTML5 data attributes
16846 <span data-foo="bar">Baz</span>
16847 <p data-abc-def_hij="">Quuz</p>
16849 <p><span data-foo="bar">Baz</span>
16851 <p data-abc-def_hij="">Quuz</p>
16856 percent-encoding and + signs in internal links (Bug 26410)
16858 [[User:+%]] [[Page+title%]]
16859 [[%+]] [[%+|%20]] [[%+ ]] [[%+r]]
16860 [[%]] [[+]] [[image:%+abc%39|foo|[[bar]]]]
16861 [[%33%45]] [[%33%45+]]
16863 <p><a href="/index.php?title=User:%2B%25&action=edit&redlink=1" class="new" title="User:+% (page does not exist)">User:+%</a> <a href="/index.php?title=Page%2Btitle%25&action=edit&redlink=1" class="new" title="Page+title% (page does not exist)">Page+title%</a>
16864 <a href="/index.php?title=%25%2B&action=edit&redlink=1" class="new" title="%+ (page does not exist)">%+</a> <a href="/index.php?title=%25%2B&action=edit&redlink=1" class="new" title="%+ (page does not exist)">%20</a> <a href="/index.php?title=%25%2B&action=edit&redlink=1" class="new" title="%+ (page does not exist)">%+ </a> <a href="/index.php?title=%25%2Br&action=edit&redlink=1" class="new" title="%+r (page does not exist)">%+r</a>
16865 <a href="/index.php?title=%25&action=edit&redlink=1" class="new" title="% (page does not exist)">%</a> <a href="/index.php?title=%2B&action=edit&redlink=1" class="new" title="+ (page does not exist)">+</a> <a href="/index.php?title=Special:Upload&wpDestFile=%25%2Babc9" class="new" title="File:%+abc9">bar</a>
16866 <a href="/index.php?title=3E&action=edit&redlink=1" class="new" title="3E (page does not exist)">3E</a> <a href="/index.php?title=3E%2B&action=edit&redlink=1" class="new" title="3E+ (page does not exist)">3E+</a>
16871 Special characters in embedded file links (bug 27679)
16873 [[File:Contains & ampersand.jpg]]
16874 [[File:Does not exist.jpg|Title with & ampersand]]
16876 <p><a href="/index.php?title=Special:Upload&wpDestFile=Contains_%26_ampersand.jpg" class="new" title="File:Contains & ampersand.jpg">File:Contains & ampersand.jpg</a>
16877 <a href="/index.php?title=Special:Upload&wpDestFile=Does_not_exist.jpg" class="new" title="File:Does not exist.jpg">Title with & ampersand</a>
16883 Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)
16885 Text's been normalized?
16887 <p>Text's been normalized?
16892 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate free external links
16894 http://www.example.org/ <-- U+3000 (vim: ^Vu3000)
16896 <p><a rel="nofollow" class="external free" href="http://www.example.org/">http://www.example.org/</a> <-- U+3000 (vim: ^Vu3000)
16901 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links
16903 [http://www.example.org/ ideograms]
16905 <p><a rel="nofollow" class="external text" href="http://www.example.org/">ideograms</a>
16910 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate external images links
16912 http://www.example.org/pic.png <-- U+3000 (vim: ^Vu3000)
16914 <p><img src="http://www.example.org/pic.png" alt="pic.png" /> <-- U+3000 (vim: ^Vu3000)
16938 Bug 31098 Template which includes system messages which includes the template
16942 <p><span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
16943 <span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
16948 Bug31490 Turkish: ucfirst 'blah'
16959 Bug31490 Turkish: ucfirst 'ix'
16970 Bug31490 Turkish: lcfirst 'BLAH'
16981 Bug31490 Turkish: ucfırst (with a dotless i)
16987 <p><a href="/index.php?title=%C5%9Eablon:Ucf%C4%B1rst:blah&action=edit&redlink=1" class="new" title="Şablon:Ucfırst:blah (sayfa mevcut değil)">Şablon:Ucfırst:blah</a>
16992 Bug31490 ucfırst (with a dotless i) with English language
16998 <p><a href="/index.php?title=Template:Ucf%C4%B1rst:blah&action=edit&redlink=1" class="new" title="Template:Ucfırst:blah (page does not exist)">Template:Ucfırst:blah</a>
17003 Bug 26375: TOC with italics
17005 title=[[Main Page]]
17008 == ''Lost'' episodes ==
17010 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17012 <li class="toclevel-1 tocsection-1"><a href="#Lost_episodes"><span class="tocnumber">1</span> <span class="toctext"><i>Lost</i> episodes</span></a></li>
17016 <h2><span class="mw-headline" id="Lost_episodes"><i>Lost</i> episodes</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Lost episodes">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17021 Bug 26375: TOC with bold
17023 title=[[Main Page]]
17026 == '''should be bold''' then normal text ==
17028 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17030 <li class="toclevel-1 tocsection-1"><a href="#should_be_bold_then_normal_text"><span class="tocnumber">1</span> <span class="toctext"><b>should be bold</b> then normal text</span></a></li>
17034 <h2><span class="mw-headline" id="should_be_bold_then_normal_text"><b>should be bold</b> then normal text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: should be bold then normal text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17039 Bug 33845: Headings become cursive in TOC when they contain an image
17041 title=[[Main Page]]
17044 == Image [[Image:foobar.jpg]] ==
17046 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17048 <li class="toclevel-1 tocsection-1"><a href="#Image"><span class="tocnumber">1</span> <span class="toctext">Image</span></a></li>
17052 <h2><span class="mw-headline" id="Image">Image <a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Image">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17057 Bug 33845 (2): Headings become bold in TOC when they contain a blockquote
17059 title=[[Main Page]]
17062 == <blockquote>Quote</blockquote> ==
17064 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17066 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
17070 <h2><span class="mw-headline" id="Quote"><blockquote>Quote</blockquote></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Quote">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17075 Unclosed tags in TOC
17077 title=[[Main Page]]
17081 <small>Hanc marginis exiguitas non caperet.</small>
17084 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17086 <li class="toclevel-1 tocsection-1"><a href="#Proof:_2_.3C_3"><span class="tocnumber">1</span> <span class="toctext">Proof: 2 < 3</span></a></li>
17090 <h2><span class="mw-headline" id="Proof:_2_.3C_3">Proof: 2 < 3</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Proof: 2 < 3">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17091 <p><small>Hanc marginis exiguitas non caperet.</small>
17097 Multiple tags in TOC
17100 == <i>Foo</i> <b>Bar</b> ==
17102 == <i>Foo</i> <blockquote>Bar</blockquote> ==
17104 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17106 <li class="toclevel-1 tocsection-1"><a href="#Foo_Bar"><span class="tocnumber">1</span> <span class="toctext"><i>Foo</i> <b>Bar</b></span></a></li>
17107 <li class="toclevel-1 tocsection-2"><a href="#Foo_Bar_2"><span class="tocnumber">2</span> <span class="toctext"><i>Foo</i> Bar</span></a></li>
17111 <h2><span class="mw-headline" id="Foo_Bar"><i>Foo</i> <b>Bar</b></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Foo Bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17112 <h2><span class="mw-headline" id="Foo_Bar_2"><i>Foo</i> <blockquote>Bar</blockquote></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Foo Bar">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17117 Tags with parameters in TOC
17120 == <sup class="in-h2">Hello</sup> ==
17122 == <sup class="a > b">Evilbye</sup> ==
17124 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17126 <li class="toclevel-1 tocsection-1"><a href="#Hello"><span class="tocnumber">1</span> <span class="toctext"><sup>Hello</sup></span></a></li>
17127 <li class="toclevel-1 tocsection-2"><a href="#b.22.3EEvilbye"><span class="tocnumber">2</span> <span class="toctext"><sup> b">Evilbye</sup></span></a></li>
17131 <h2><span class="mw-headline" id="Hello"><sup class="in-h2">Hello</sup></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Hello">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17132 <h2><span class="mw-headline" id="b.22.3EEvilbye"><sup> b">Evilbye</sup></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: b">Evilbye">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17137 span tags with directionality in TOC
17140 == <span dir="ltr">C++</span> ==
17142 == <span dir="rtl">זבנג!</span> ==
17144 == <span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span> ==
17146 == <span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span> ==
17148 == <span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span> ==
17150 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
17152 <li class="toclevel-1 tocsection-1"><a href="#C.2B.2B"><span class="tocnumber">1</span> <span class="toctext"><span dir="ltr">C++</span></span></a></li>
17153 <li class="toclevel-1 tocsection-2"><a href="#.D7.96.D7.91.D7.A0.D7.92.21"><span class="tocnumber">2</span> <span class="toctext"><span dir="rtl">זבנג!</span></span></a></li>
17154 <li class="toclevel-1 tocsection-3"><a href="#The_attributes_on_these_span_tags_must_be_deleted_from_the_TOC"><span class="tocnumber">3</span> <span class="toctext"><span>The attributes on these span tags must be deleted from the TOC</span></span></a></li>
17155 <li class="toclevel-1 tocsection-4"><a href="#All_attributes_on_these_span_tags_must_be_deleted_from_the_TOC"><span class="tocnumber">4</span> <span class="toctext"><span>All attributes on these span tags must be deleted from the TOC</span></span></a></li>
17156 <li class="toclevel-1 tocsection-5"><a href="#Attributes_after_dir_on_these_span_tags_must_be_deleted_from_the_TOC"><span class="tocnumber">5</span> <span class="toctext"><span dir="ltr">Attributes after dir on these span tags must be deleted from the TOC</span></span></a></li>
17160 <h2><span class="mw-headline" id="C.2B.2B"><span dir="ltr">C++</span></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: C++">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17161 <h2><span class="mw-headline" id=".D7.96.D7.91.D7.A0.D7.92.21"><span dir="rtl">זבנג!</span></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: זבנג!">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17162 <h2><span class="mw-headline" id="The_attributes_on_these_span_tags_must_be_deleted_from_the_TOC"><span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: The attributes on these span tags must be deleted from the TOC">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17163 <h2><span class="mw-headline" id="All_attributes_on_these_span_tags_must_be_deleted_from_the_TOC"><span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: All attributes on these span tags must be deleted from the TOC">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17164 <h2><span class="mw-headline" id="Attributes_after_dir_on_these_span_tags_must_be_deleted_from_the_TOC"><span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Attributes after dir on these span tags must be deleted from the TOC">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17171 == {{int:headline_sample}} ==
17175 Bug 32057: Title needed when expanding <h> nodes.
17177 title=[[Main Page]]
17181 <h2><span class="mw-headline" id="Headline_text">Headline text</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Headline text">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17186 Strip marker in urlencode
17188 {{urlencode:x<nowiki/>y}}
17189 {{urlencode:x<nowiki/>y|wiki}}
17190 {{urlencode:x<nowiki/>y|path}}
17217 Strip marker in formatNum
17219 {{formatnum:1<nowiki/>2}}
17220 {{formatnum:1<nowiki/>2|R}}
17228 Check noCommafy in formatNum
17232 {{formatnum:123456.78}}
17233 {{formatnum:123456.78|NOSEP}}
17241 Wrong option for formatNum (bug 56199)
17243 {{formatnum:1,234.56|Random}}
17244 {{formatnum:1,234.56|EVERYTHING}}
17245 {{formatnum:1234.56|any argument that has the string 'NOSEP'}}
17254 Strip marker in grammar
17258 {{grammar:elative|foo<nowiki/>bar}}
17265 Strip marker in padleft
17267 {{padleft:|2|x<nowiki/>y}}
17274 Strip marker in padright
17276 {{padright:|2|x<nowiki/>y}}
17283 Strip marker in anchorencode
17285 {{anchorencode:x<nowiki/>y}}
17292 nowiki inside link inside heading (bug 18295)
17294 ==[[foo|x<nowiki>y</nowiki>z]]==
17296 <h2><span class="mw-headline" id="xyz"><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">xyz</a></span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: xyz">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17301 new support for bdi element (bug 31817)
17303 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
17305 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
17310 Ignore pipe between table row attributes
17314 |- id=foo | style='color: red'
17322 <tr id="foo" style="color: red">
17329 Gallery override link with WikiLink (bug 34852)
17332 File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
17335 <ul class="gallery mw-gallery-traditional">
17336 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
17337 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/InterWikiLink"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
17338 <div class="gallerytext">
17348 Gallery override link with absolute external link (bug 34852)
17351 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
17354 <ul class="gallery mw-gallery-traditional">
17355 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
17356 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="http://www.example.org"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
17357 <div class="gallerytext">
17367 Gallery override link with malicious javascript (bug 34852)
17370 File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
17373 <ul class="gallery mw-gallery-traditional">
17374 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
17375 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/%22_onclick%3D%22alert(%27malicious_javascript_code!%27);"><img alt="galleryalt" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
17376 <div class="gallerytext">
17386 Gallery with invalid title as link (bug 43964)
17389 File:foobar.jpg|link=<
17392 <ul class="gallery mw-gallery-traditional">
17393 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
17394 <div class="thumb" style="width: 150px;"><div style="margin:68px auto;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" src="http://example.com/images/thumb/3/3a/Foobar.jpg/120px-Foobar.jpg" width="120" height="14" /></a></div></div>
17395 <div class="gallerytext">
17403 Language parser function
17412 Padleft and padright as substr
17414 {{padleft:|3|abcde}}
17415 {{padright:|3|abcde}}
17423 Special parser function
17425 {{#special:RandomPage}}
17426 {{#special:BaDtItLe}}
17427 {{#special:Foobar}}
17436 Bug 34939 - Case insensitive link parsing ([HttP://])
17438 [HttP://MediaWiki.Org/]
17440 <p><a rel="nofollow" class="external autonumber" href="HttP://MediaWiki.Org/">[1]</a>
17443 <p><a rel="mw:ExtLink" href="HttP://MediaWiki.Org/"></a></p>
17447 Bug 34939 - Case insensitive link parsing ([HttP:// title])
17449 [HttP://MediaWiki.Org/ MediaWiki]
17451 <p><a rel="nofollow" class="external text" href="HttP://MediaWiki.Org/">MediaWiki</a>
17456 Bug 34939 - Case insensitive link parsing (HttP://)
17458 HttP://MediaWiki.Org/
17460 <p><a rel="nofollow" class="external free" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a>
17463 <p><a rel="mw:ExtLink" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a></p>
17481 <h2><span class="mw-headline" id="Section_1">Section 1</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section 1">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17482 <h2><span class="mw-headline" id="Section_2">Section 2</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Section 2">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17483 <h2><span class="mw-headline" id="Section_3">Section 3</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Section 3">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17484 <h2><span class="mw-headline" id="Section_4">Section 4</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Section 4">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17485 <h2><span class="mw-headline" id="Section_5">Section 5</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Section 5">edit</a><span class="mw-editsection-bracket">]</span></span></h2>
17491 ### Parsoids-specific tests
17492 ### Parsoid-PHP parser incompatibilities
17495 1. SOL-sensitive wikitext tokens as template-args
17497 parsoid=wt2html,wt2wt
17503 <span about="#mwt1" typeof="mw:Transclusion">
17504 </span><ul about="#mwt1"><li>a</li>
17506 <span about="#mwt2" typeof="mw:Transclusion">
17507 </span><ol about="#mwt2"><li>a</li>
17509 <span about="#mwt3" typeof="mw:Transclusion">
17510 </span><dl about="#mwt3"><dd>a</dd>
17514 #### ----------------------------------------------------------------
17515 #### Parsoid-only testing of Parsoid's impl of <ref> and <references>
17516 #### tags. Parsoid's output for these tags differs from that of the
17518 #### ----------------------------------------------------------------
17521 Ref: 1. ref-location should be replaced with an index span
17526 B <ref name="x">foo</ref>
17529 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span>
17530 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-2">[2]</a></span>
17531 C <span about="#mwt3" class="reference" data-mw='{"name":"ref","attrs":{"name":"y"}}' id="cite_ref-y-3-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-y-3">[3]</a></span></p>
17535 Ref: 2. ref-tags with identical names should all get the same index
17539 A <ref name="x">foo</ref>
17542 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
17543 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span></p>
17547 Ref: 3. spaces in ref-names should be ignored
17551 A <ref name="x">foo</ref>
17552 B <ref name=" x " />
17555 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"x"}}' id="cite_ref-x-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
17556 B <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span>
17557 C <span about="#mwt3" class="reference" data-mw='{"name":"ref","attrs":{"name":"x"}}' id="cite_ref-x-1-2" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-x-1">[1]</a></span></p>
17561 Ref: 4. 'constructor' should be accepted as a valid ref-name
17562 (NOTE: constructor is a predefined property in JS and constructor as a ref-name can clash with it if not handled properly)
17566 A <ref name="constructor">foo</ref>
17568 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"constructor"}}' id="cite_ref-constructor-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-constructor-1">[1]</a></span></p>
17572 Ref: 5. body should accept generic wikitext
17577 This is a '''[[bolded link]]''' and this is a {{echo|transclusion}}
17582 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"This is a <b data-parsoid='{\"dsr\":[19,40,3,3]}'><a rel=\"mw:WikiLink\" href=\"./Bolded_link\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Bolded_link\"},\"sa\":{\"href\":\"bolded link\"},\"dsr\":[22,37,2,2]}'>bolded link</a></b> and this is a <span about=\"#mwt3\" typeof=\"mw:Transclusion\" data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"echo\",\"href\":\"./Template:Echo\"},\"params\":{\"1\":{\"wt\":\"transclusion\"}},\"i\":0}}]}' data-parsoid='{\"dsr\":[55,76,null,null],\"pi\":[[{\"k\":\"1\",\"spc\":[\"\",\"\",\"\",\"\"]}]]}'>transclusion</span>\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
17584 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
17585 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> This is a <b><a rel="mw:WikiLink" href="./Bolded_link">bolded link</a></b> and this is a <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"transclusion"}},"i":0}}]}'>transclusion</span>
17591 Ref: 6. indent-pres should not be output in ref-body
17603 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo\n bar\n baz\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
17605 <ol class="references" typeof="mw:Extension/references" about="#mwt3" data-mw='{"name":"references","attrs":{}}'>
17606 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
17614 Ref: 7. No p-wrapping in ref-body
17633 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo\n\nbar\n\n\nbaz\n\n\n\nbooz\n"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
17635 <ol about="#mwt2" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'>
17636 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
17651 Ref: 8. transclusion wikitext has lower precedence
17655 A <ref> foo {{echo|</ref> B C}}
17659 <p>A <span class="reference" data-mw="{"name":"ref","body":{"html":"foo <span typeof=\"mw:Nowiki\" data-parsoid='{\"src\":\"{{\",\"dsr\":[12,14,0,0]}'>{{</span>echo|"},"attrs":{}}" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> B C<span typeof="mw:Nowiki">}}</span></p>
17660 <ol class="references" typeof="mw:Extension/references" data-mw="{"name":"references","attrs":{}}">
17661 <li id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <span typeof="mw:Nowiki">{{</span>echo|</li>
17666 Ref: 9. unclosed comments should not leak out of ref-body
17670 A <ref> foo <!--</ref> B C
17673 <p>A <span class="reference" data-mw='{"name":"ref","body":{"html":"foo <!---->"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> B C</p>
17674 <ol class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'>
17675 <li id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo </li>
17680 Ref: 10. Unclosed HTML tags should not leak out of ref-body
17684 A <ref> <b> foo </ref> B C
17688 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"<b data-parsoid='{\"stx\":\"html\",\"autoInsertedEnd\":true,\"dsr\":[8,16,3,0]}'> foo </b>"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref> <b> foo </ref>"}'><a href="#cite_note-1">[1]</a></span> B C</p>
17691 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-parsoid='{"src":"<references />"}' data-mw='{"name":"references","attrs":{}}'>
17692 <li about="#cite_note-1" id="cite_note-1" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> <b data-parsoid='{"stx":"html","autoInsertedEnd":true}'> foo </b></li>
17697 Ref: 11. ref-tags acts like an inline element wrt P-wrapping
17704 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo</ref>"}'><a href="#cite_note-1">[1]</a></span> B
17705 C <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>bar</ref>"}'><a href="#cite_note-2">[2]</a></span> D</p>
17709 Ref: 12. ref-tags act as trailing newline migration barrier
17713 <!--the newline at the end of this line moves out of the p-tag-->a
17715 b<!--the newline at the end of this line stays inside the p-tag--> <ref />
17720 <p><!--the newline at the end of this line moves out of the p-tag-->a</p>
17723 <p>b<!--the newline at the end of this line stays inside the p-tag--> <span about="#mwt1" class="reference" data-mw='{"name":"ref","attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span>
17724 <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[2]</a></span></p>
17731 Ref: 13. ref-tags are not SOL-transparent and block indent-pres
17739 <p><span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> A
17740 <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"bar\n"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[2]</a></span> B</p>
17744 Ref: 14. A nested ref-tag should be emitted as plain text
17748 <ref>foo <ref>bar</ref> baz</ref>
17752 <p><span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo &lt;ref>bar&lt;/ref> baz"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo <ref>bar</ref> baz</ref>"}'><a href="#cite_note-1">[1]</a></span></p>
17754 <ol class="references" typeof="mw:Extension/references" about="#mwt5" data-parsoid='{"src":"<references />"}' data-mw='{"name":"references","attrs":{}}'>
17755 <li about="#cite_note-1" id="cite_note-1" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <ref>bar</ref> baz</li>
17760 Ref: 15. ref-tags with identical names should get identical indexes
17764 A1 <ref name="a">foo</ref> A2 <ref name="a" />
17765 B1 <ref name="b" /> B2 <ref name="b">bar</ref>
17769 <p>A1 <span about="#mwt3" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"name":"a"}}' id="cite_ref-a-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-a-1">[1]</a></span> A2 <span about="#mwt4" class="reference" data-mw='{"name":"ref","attrs":{"name":"a"}}' id="cite_ref-a-1-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-a-1">[1]</a></span>
17770 B1 <span about="#mwt7" class="reference" data-mw='{"name":"ref","attrs":{"name":"b"}}' id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-b-2">[2]</a></span> B2 <span about="#mwt8" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"name":"b"}}' id="cite_ref-b-2-1" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-b-2">[2]</a></span></p>
17772 <ol about="#mwt10" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-a-1" id="cite_note-a-1"><span rel="mw:referencedBy">↑ <a href="#cite_ref-a-1-0">1.0</a> <a href="#cite_ref-a-1-1">1.1</a></span> foo</li><li about="#cite_note-b-2" id="cite_note-b-2"><span rel="mw:referencedBy">↑ <a href="#cite_ref-b-2-0">2.0</a> <a href="#cite_ref-b-2-1">2.1</a></span> bar</li>
17776 ## We don't bother wt2wt-ing non-standard whitespace
17778 Ref: 16. Tokenizer should accept non-standard whitespace in <ref> and </ref> tags
17786 <p>A <span class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
17788 <ol class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'>
17789 <li id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li></ol>
17793 References: 1. references tag without any refs should be handled properly
17799 <ol about="#mwt2" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'></ol>
17803 References: 2. references tag with group only outputs references from that group
17807 A <ref group="a">foo</ref>
17808 B <ref group="b">bar</ref>
17810 <references group="a" />
17812 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{"group":"a"}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[a 1]</a></span>
17813 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"group":"b"}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[b 1]</a></span></p>
17815 <ol about="#mwt6" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{"group":"a"}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li>
17820 References: 3. ref list should be cleared after processing references
17832 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
17834 <ol about="#mwt4" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li>
17837 <p>B <span about="#mwt6" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[1]</a></span></p>
17839 <ol about="#mwt8" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-2" id="cite_note-2"><span rel="mw:referencedBy"><a href="#cite_ref-2-0">↑</a></span> bar</li>
17844 References: 4. only referenced group should be cleared after processing references
17848 A <ref group="a">afoo</ref>
17851 <references group="a" />
17857 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"afoo"},"attrs":{"group":"a"}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[a 1]</a></span>
17858 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bfoo"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>bfoo</ref>"}'><a href="#cite_note-2">[1]</a></span></p>
17860 <ol about="#mwt6" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{"group":"a"}}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> afoo</li>
17863 <p>C <span about="#mwt8" class="reference" data-mw='{"name":"ref","body":{"html":"cfoo"},"attrs":{}}' id="cite_ref-3-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-3">[2]</a></span></p>
17865 <ol about="#mwt10" class="references" typeof="mw:Extension/references" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-2" id="cite_note-2"><span rel="mw:referencedBy"><a href="#cite_ref-2-0">↑</a></span> bfoo</li><li about="#cite_note-3" id="cite_note-3"><span rel="mw:referencedBy"><a href="#cite_ref-3-0">↑</a></span> cfoo</li>
17870 References: 5. ref tags in references should be processed while ignoring all other content
17875 B <ref name="b">bar</ref>
17878 <ref name="a">foo</ref>
17879 This should just get lost.
17882 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","attrs":{"name":"a"}}' id="cite_ref-a-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref name=\"a\" />"}'><a href="#cite_note-a-1">[1]</a></span>
17883 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"name":"b"}}' id="cite_ref-b-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref name=\"b\">bar</ref>"}'><a href="#cite_note-b-2">[2]</a></span></p>
17886 <ol class="references" typeof="mw:Extension/references" about="#mwt6" data-parsoid='{"src":"<references>\n<ref name=\"a\">foo</ref>\nThis should just get lost.\n</references>"}' data-mw='{"name":"references","body":{"extsrc":"<ref name=\"a\">foo</ref>\nThis should just get lost.","html":"\n<span about=\"#mwt8\" class=\"reference\" data-mw='{\"name\":\"ref\",\"body\":{\"html\":\"foo\"},\"attrs\":{\"name\":\"a\"}}' rel=\"dc:references\" typeof=\"mw:Extension/ref\"><a href=\"#cite_note-a-1\">[1]</a></span>\n"},"attrs":{}}'>
17887 <li about="#cite_note-a-1" id="cite_note-a-1" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-a-1-0">↑</a></span> foo</li>
17888 <li about="#cite_note-b-2" id="cite_note-b-2" data-parsoid="{}"><span rel="mw:referencedBy"><a href="#cite_ref-b-2-0">↑</a></span> bar</li>
17893 References: 6. <references /> from a transclusion
17897 <ref>Foo</ref> {{echo|<references />}}
17899 <span about="#mwt3" class="reference" data-mw='{"name":"ref","body":{"html":"Foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> <ol class="references" typeof="mw:Extension/references mw:Transclusion" about="#mwt4" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<references />"}},"i":0}}]}'><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> Foo</li></ol>
17903 References: 7. Multiple references tags (one without and one with nested refs) should be correctly handled
17907 A <ref>foo bar for a</ref>
17908 B <ref group="X" name="b" />
17912 <references group="X">
17913 <ref name="b">foo</ref>
17916 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo bar for a"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo bar for a</ref>"}'><a href="#cite_note-2" data-parsoid="{}">[2]</a></span>
17917 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","attrs":{"group":"X","name":"b"}}' id="cite_ref-b-3-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref name=\"b\" group=\"X\" />"}'><a href="#cite_note-b-3" data-parsoid="{}">[X 1]</a></span></p>
17919 <ol class="references" typeof="mw:Extension/references" about="#mwt6" data-parsoid='{"src":"<references />"}' data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-b-1" id="cite_note-b-1" data-parsoid="{}"><span rel="mw:referencedBy" data-parsoid="{}">↑</span> foo</li><li about="#cite_note-2" id="cite_note-2" data-parsoid="{}"><span rel="mw:referencedBy" data-parsoid="{}"><a href="#cite_ref-2-0" data-parsoid="{}">↑</a></span> foo bar for a</li></ol>
17921 <ol class="references" typeof="mw:Extension/references" about="#mwt8" data-parsoid='{"src":"<references group=\"X\">\n<ref name=\"b\">foo</ref>\n</references>","group":"X"}' data-mw='{"name":"references","body":{"extsrc":"<ref name=\"b\">foo</ref>","html":"\n<span about=\"#mwt10\" class=\"reference\" data-mw='{\"name\":\"ref\",\"body\":{\"html\":\"foo\"},\"attrs\":{\"name\":\"b\"}}' rel=\"dc:references\" typeof=\"mw:Extension/ref\"><a href=\"#cite_note-b-1\">[1]</a></span>\n"},"attrs":{"group":"X"}}'><li about="#cite_note-b-3" id="cite_note-b-3" data-parsoid="{}"><span rel="mw:referencedBy" data-parsoid="{}"><a href="#cite_ref-b-3-0" data-parsoid="{}">↑</a></span> </li></ol>
17925 Entities in ref name
17929 <ref name="test & me">hi</ref>
17931 <p data-parsoid='{}'><span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"hi"},"attrs":{"name":"test & me"}}' id="cite_ref-test & me-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref name=\"test &amp; me\">hi</ref>"}'><a href="#cite_note-test & me-1" data-parsoid="{}">[1]</a></span></p>
17934 # This test is wt2html only because we're permitting the serializer to produce
17935 # dirty diffs, normalizing the unclosed references to the self-closed version.
17937 Generate references for unclosed references tag
17945 <p data-parsoid='{}'>a<span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>foo</ref>"}'><a href="#cite_note-1" data-parsoid="{}">[1]</a></span></p>
17948 <ol class="references" typeof="mw:Extension/references" about="#mwt4" data-parsoid='{"src":"<references>"}' data-mw='{"name":"references","attrs":{}}'>
17949 <li about="#cite_note-1" id="cite_note-1" data-parsoid="{}"><span rel="mw:referencedBy" data-parsoid="{}"><a href="#cite_ref-1-0" data-parsoid="{}">↑</a></span> foo</li></ol>
17953 New reference serializes on its own line
17955 parsoid=wt2wt,html2wt
17960 foo<ol class="references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>
17963 #### ----------------------------------------------------------------
17964 #### The following section of tests are primarily to test
17965 #### wikitext escaping capabilities of Parsoid. Given that
17966 #### escaping can be done any number of ways, the wikitext (input)
17967 #### is always adjusted to reflect how Parsoid adds nowiki
17970 #### We are marking several tests as parsoid-only since the
17971 #### HTML in the result section is different from what the
17972 #### PHP parser generates for it.
17973 #### ----------------------------------------------------------------
17976 #### --------------- Headings ---------------
17978 #### 1. Nested inside html <h1>=foo=</h1>
17979 #### 2. Outside heading nest on a single line <h1>foo</h1>*bar
17980 #### 3. Nested inside html with wikitext split by html tags
17981 #### 4. No escape needed
17982 #### 5. Empty headings <h1></h1>
17983 #### 6. Heading chars in SOL context
17984 #### ----------------------------------------
17986 Headings: 0. Unnested
17990 <nowiki>=foo=</nowiki>
17992 <nowiki> =foo= </nowiki>
17994 <nowiki>=foo=</nowiki>
17996 =foo''a''<nowiki>=</nowiki>
17998 <p><span typeof="mw:Nowiki">=foo=</span></p>
18000 <p><span typeof="mw:Nowiki"> =foo= </span>
18002 <span typeof="mw:Nowiki">=foo=</span></p>
18004 <p>=foo<i>a</i><span typeof="mw:Nowiki">=</span></p>
18008 Headings: 1. Nested inside html
18009 (New headings and existing headings are handled differently)
18019 =<nowiki>=foo=</nowiki>=
18020 ==<nowiki>=foo=</nowiki>==
18021 ===<nowiki>=foo=</nowiki>===
18022 ====<nowiki>=foo=</nowiki>====
18023 =====<nowiki>=foo=</nowiki>=====
18024 ======<nowiki>=foo=</nowiki>======
18031 <h1 data-parsoid='{}'>=foo=</h1>
18032 <h2 data-parsoid='{}'>=foo=</h2>
18033 <h3 data-parsoid='{}'>=foo=</h3>
18034 <h4 data-parsoid='{}'>=foo=</h4>
18035 <h5 data-parsoid='{}'>=foo=</h5>
18036 <h6 data-parsoid='{}'>=foo=</h6>
18040 Headings: 2. Outside heading nest on a single line <h1>foo</h1>*bar
18045 <nowiki>*</nowiki>bar
18051 <nowiki>=bar=</nowiki>
18059 Headings: 3. Nested inside html with wikitext split by html tags
18063 = ='''bold'''<nowiki>foo=</nowiki> =
18065 <h1>=<b>bold</b><span typeof="mw:Nowiki">foo=</span></h1>
18069 Headings: 4a. No escaping needed (testing just h1 and h2)
18087 = <nowiki>=</nowiki> =
18095 <h1><i>=</i>foo=</h1>
18096 <h1><span typeof="mw:Nowiki">=</span></h1>
18100 Headings: 4b. No escaping needed (inside p-tags)
18115 Headings: 5. Empty headings
18127 =====<nowiki/>=====
18129 ======<nowiki/>======
18140 Headings: 6a. Heading chars in SOL context (with trailing spaces)
18144 <nowiki>=a=</nowiki>
18146 <nowiki>=a=</nowiki>
18148 <nowiki>=a=</nowiki>
18150 <nowiki>=a=</nowiki>
18159 Headings: 6b. Heading chars in SOL context (with trailing newlines)
18187 Headings: 6c. Heading chars in SOL context (leading newline break)
18192 <nowiki>=b=</nowiki>
18199 Headings: 6d. Heading chars in SOL context (with interspersed comments)
18203 <!--c0--><nowiki>=a=</nowiki>
18205 <!--c1--><nowiki>=a=</nowiki> <!--c2--> <!--c3-->
18207 <p><!--c0-->=a=</p>
18208 <p><!--c1-->=a= <!--c2--> <!--c3--></p>
18212 Headings: 6d. Heading chars in SOL context (No escaping needed)
18221 #### --------------- Lists ---------------
18222 #### 0. Outside nests (*foo, etc.)
18223 #### 1. Nested inside html <ul><li>*foo</li></ul>
18224 #### 2. Inside definition lists
18225 #### 3. Only bullets at start should be escaped
18226 #### 4. No escapes needed
18227 #### 5. No unnecessary escapes
18228 #### 6. Escape bullets in SOL position
18229 #### 7. Escape bullets in a multi-line context
18230 #### ----------------------------------------
18233 Lists: 0. Outside nests
18235 <nowiki>*</nowiki>foo
18237 <nowiki>#</nowiki>foo
18245 Lists: 1. Nested inside html
18247 *<nowiki>*foo</nowiki>
18249 *<nowiki>#foo</nowiki>
18251 *<nowiki>:foo</nowiki>
18253 *<nowiki>;foo</nowiki>
18255 #<nowiki>*foo</nowiki>
18257 #<nowiki>#foo</nowiki>
18259 #<nowiki>:foo</nowiki>
18261 #<nowiki>;foo</nowiki>
18263 <ul><li>*foo</li></ul>
18264 <ul><li>#foo</li></ul>
18265 <ul><li>:foo</li></ul>
18266 <ul><li>;foo</li></ul>
18267 <ol><li>*foo</li></ol>
18268 <ol><li>#foo</li></ol>
18269 <ol><li>:foo</li></ol>
18270 <ol><li>;foo</li></ol>
18275 Lists: 2. Inside definition lists
18277 ;<nowiki>;foo</nowiki>
18279 ;<nowiki>:foo</nowiki>
18281 ;<nowiki>:foo</nowiki>
18284 :<nowiki>:foo</nowiki>
18286 <dl><dt>;foo</dt></dl>
18287 <dl><dt>:foo</dt></dl>
18290 <dl><dd>:foo</dd></dl>
18295 Lists: 3. Only bullets at start of text should be escaped
18297 *<nowiki>*foo*bar</nowiki>
18299 *<nowiki>*foo</nowiki>''it''*bar
18301 <ul><li>*foo*bar</li></ul>
18302 <ul><li>*foo<i>it</i>*bar</li></ul>
18307 Lists: 4. No escapes needed
18328 <li><a rel="mw:WikiLink" href="Foo">Foo</a>: bar
18332 <li><a rel="mw:WikiLink" href="Foo">Foo</a>*bar
18338 Lists: 5. No unnecessary escapes
18340 * bar <span><nowiki>[[foo]]</nowiki></span>
18342 *=bar <span><nowiki>[[foo]]</nowiki></span>
18344 *[[bar <span><nowiki>[[foo]]</nowiki></span>
18346 *]]bar <span><nowiki>[[foo]]</nowiki></span>
18348 *=bar <span>foo]]</span>=
18352 <ul><li> bar <span>[[foo]]</span></li></ul>
18353 <ul><li>=bar <span>[[foo]]</span></li></ul>
18354 <ul><li>[[bar <span>[[foo]]</span></li></ul>
18355 <ul><li>]]bar <span>[[foo]]</span></li></ul>
18356 <ul><li>=bar <span>foo]]</span>=</li></ul>
18357 <ul><li> <s></s>: a</li></ul>
18362 Lists: 6. Escape bullets in SOL position
18366 <!--cmt--><nowiki>*foo</nowiki>
18368 <p><!--cmt--><span typeof="mw:Nowiki">*foo</span></p>
18372 Lists: 7. Escape bullets in a multi-line context
18375 <nowiki>*</nowiki>b
18382 #### --------------- HRs ---------------
18383 #### 1. Single line
18384 #### -----------------------------------
18387 HRs: 1. Single line
18391 ----<nowiki>----</nowiki>
18395 <hr><span typeof="mw:Nowiki">----</span>
18400 #### --------------- Tables ---------------
18401 #### 1a. Simple example
18402 #### 1b. No escaping needed (!foo)
18403 #### 1c. No escaping needed (|foo)
18404 #### 1d. No escaping needed (|}foo)
18406 #### 2a. Nested in td (<td>foo|bar</td>)
18407 #### 2b. Nested in td (<td>foo||bar</td>)
18408 #### 2c. Nested in td -- no escaping needed(<td>foo!!bar</td>)
18410 #### 3a. Nested in th (<th>foo!bar</th>)
18411 #### 3b. Nested in th (<th>foo!!bar</th>)
18412 #### 3c. Nested in th -- no escaping needed(<th>foo||bar</th>)
18416 #### 4c. No escaping needed
18417 #### --------------------------------------
18420 Tables: 1a. Simple example
18431 Tables: 1b. No escaping needed
18440 Tables: 1c. No escaping needed
18449 Tables: 1d. No escaping needed
18458 Tables: 2a. Nested in td
18463 |<nowiki>foo|bar</nowiki>
18465 |x<div><nowiki>a|b</nowiki></div>
18469 <td>foo|bar</td></tr>
18470 <tr><td>x<div>a|b</div></td>
18475 Tables: 2b. Nested in td
18480 |<nowiki>foo||bar</nowiki>
18481 |''it''<nowiki>foo||bar</nowiki>
18485 <td><span typeof="mw:Nowiki">foo||bar</span></td>
18486 <td><i>it</i><span typeof="mw:Nowiki">foo||bar</span></td></tr></tbody></table>
18490 Tables: 2c. Nested in td -- no escaping needed
18498 <table><tbody><tr><td>foo!!bar
18499 </td></tr></tbody></table>
18504 Tables: 3a. Nested in th
18512 <table><tbody><tr><th>foo!bar
18513 </th></tr></tbody></table>
18518 Tables: 3b. Nested in th
18523 !<nowiki>foo!!bar</nowiki>
18527 <tbody><tr><th><span typeof="mw:Nowiki">foo!!bar</span></th></tr>
18532 Tables: 3c. Nested in th -- no escaping needed
18537 !<nowiki>foo||bar</nowiki>
18541 <th><span typeof="mw:Nowiki">foo||bar</span></th></tr></tbody></table>
18545 Tables: 4a. Escape -
18552 |<nowiki>-bar</nowiki>
18556 <tr><th>-bar</th></tr>
18558 <td><span typeof="mw:Nowiki">-bar</span></td></tr></tbody></table>
18562 Tables: 4b. Escape +
18569 |<nowiki>+bar</nowiki>
18573 <tr><th>+bar</th></tr>
18575 <td><span typeof="mw:Nowiki">+bar</span></td></tr></tbody></table>
18579 Tables: 4c. No escaping needed
18600 <tr><td>foo-bar</td><td>foo+bar</td></tr>
18601 <tr><td><i>foo</i>-bar</td><td><i>foo</i>+bar</td></tr>
18607 <div>a|b</div></td>
18612 Tables: 4d. No escaping needed
18623 <tbody><tr><td><a rel="mw:WikiLink" href="./Foo">Foo</a>-bar</td>
18624 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>+1</td>
18625 <td data-parsoid='{"startTagSrc":"|","attrSepSrc":"|"}'>-2</td></tr>
18630 Tables: Digest broken attributes on table and tr tag
18646 #### --------------- Links ----------------
18647 #### 1. Quote marks in link text
18648 #### 2. Wikilinks: Escapes needed
18649 #### 3. Wikilinks: No escapes needed
18650 #### 4. Extlinks: Escapes needed
18651 #### 5. Extlinks: No escapes needed
18652 #### --------------------------------------
18654 Links 1. Quote marks in link text
18658 [[Foo|Foo<nowiki>''boo''</nowiki>]]
18660 <a rel="mw:WikiLink" href="Foo">Foo''boo''</a>
18664 Links 2. WikiLinks: Escapes needed
18669 [[Foo|<nowiki>Foobar]</nowiki>]]
18670 [[Foo|x [Foobar] x]]
18671 [[Foo|x <nowiki>[http://google.com g]</nowiki> x]]
18672 [[Foo|<nowiki>[[Bar]]</nowiki>]]
18673 [[Foo|<nowiki>x [[Bar]] x</nowiki>]]
18674 [[Foo|<nowiki>|Bar</nowiki>]]
18675 [[Foo|<nowiki>]]bar</nowiki>]]
18676 [[Foo|<nowiki>[[bar</nowiki>]]
18677 [[Foo|<nowiki>x [[ y</nowiki>]]
18678 [[Foo|<nowiki>x ]] y</nowiki>]]
18679 [[Foo|<nowiki>x ]] y [[ z</nowiki>]]
18681 <a href="Foo" rel="mw:WikiLink">[Foobar]</a>
18682 <a href="Foo" rel="mw:WikiLink">Foobar]</a>
18683 <a href="Foo" rel="mw:WikiLink">x [Foobar] x</a>
18684 <a href="Foo" rel="mw:WikiLink">x [http://google.com g] x</a>
18685 <a href="Foo" rel="mw:WikiLink">[[Bar]]</a>
18686 <a href="Foo" rel="mw:WikiLink">x [[Bar]] x</a>
18687 <a href="Foo" rel="mw:WikiLink">|Bar</a>
18688 <a href="Foo" rel="mw:WikiLink">]]bar</a>
18689 <a href="Foo" rel="mw:WikiLink">[[bar</a>
18690 <a href="Foo" rel="mw:WikiLink">x [[ y</a>
18691 <a href="Foo" rel="mw:WikiLink">x ]] y</a>
18692 <a href="Foo" rel="mw:WikiLink">x ]] y [[ z</a>
18696 Links 3. WikiLinks: No escapes needed
18703 <a href="Foo" rel="mw:WikiLink">[Foobar</a>
18704 <a href="Foo" rel="mw:WikiLink">foo|bar</a>
18708 Links 4. ExtLinks: Escapes needed
18712 [http://google.com <nowiki>[google]</nowiki>]
18713 [http://google.com <nowiki>google]</nowiki>]
18715 <nowiki>[http://google.com]</nowiki>
18717 <nowiki>[http://google.com google]</nowiki>
18720 <p><a href="http://google.com" rel="mw:ExtLink">[google]</a>
18721 <a href="http://google.com" rel="mw:ExtLink">google]</a></p>
18722 <p>[http://google.com]</p>
18723 <p>[http://google.com google]</p>
18727 Links 5. ExtLinks: No escapes needed
18731 [http://google.com [google]
18733 <a href="http://google.com" rel="mw:ExtLink">[google</a>
18736 #### --------------- Quotes ---------------
18737 #### 1. Quotes inside <b> and <i>
18738 #### 2. Link fragments separated by <i> and <b> tags
18739 #### 3. Link fragments inside <i> and <b>
18740 #### 4. No escaping needed
18741 #### --------------------------------------
18743 1. Quotes inside <b> and <i>
18745 parsoid=html2wt,wt2wt
18747 ''<nowiki>'foo'</nowiki>''
18748 ''<nowiki>''foo''</nowiki>''
18749 ''<nowiki>'''foo'''</nowiki>''
18751 '''<nowiki>'foo'</nowiki>'''
18752 '''<nowiki>''foo''</nowiki>'''
18753 '''<nowiki>'''foo'''</nowiki>'''
18754 '''<nowiki>foo'</nowiki>''<nowiki>bar'</nowiki>''baz'''
18755 '''foo'''<nowiki/>'s
18758 '<nowiki/>''foo''<nowiki/>'
18760 '''foo'''<nowiki/>'
18761 '<nowiki/>'''foo'''<nowiki/>'
18762 ''fools'<span> errand</span>''
18763 ''<span>fool</span>'s errand''
18772 <b>foo'<i>bar'</i>baz</b>
18780 <i>fools'<span> errand</span></i>
18781 <i><span>fool</span>'s errand</i>
18785 2. Link fragments separated by <i> and <b> tags
18787 [[''foo''<nowiki>hello]]</nowiki>
18789 [['''foo'''<nowiki>hello]]</nowiki>
18791 <p>[[<i>foo</i>hello]]
18792 </p><p>[[<b>foo</b>hello]]
18797 3. Link fragments inside <i> and <b>
18798 (FIXME: Escaping one or both of [[ and ]] is also acceptable --
18799 this is one of the shortcomings of this format)
18801 ''[[foo''<nowiki>]]</nowiki>
18803 '''[[foo'''<nowiki>]]</nowiki>
18806 </p><p><b>[[foo</b>]]
18811 4. No escaping needed
18813 '<span>''bar''</span>'
18814 '<span>'''bar'''</span>'
18816 <p>'<span><i>bar</i></span>'
18817 '<span><b>bar</b></span>'
18821 #### ----------- Paragraphs ---------------
18822 #### 1. No unnecessary escapes
18823 #### --------------------------------------
18826 1. No unnecessary escapes
18828 bar <span><nowiki>[[foo]]</nowiki></span>
18830 =bar <span><nowiki>[[foo]]</nowiki></span>
18832 [[bar <span><nowiki>[[foo]]</nowiki></span>
18834 ]]bar <span><nowiki>[[foo]]</nowiki></span>
18836 =bar <span>foo]]</span><nowiki>=</nowiki>
18838 <p>bar <span>[[foo]]</span>
18839 </p><p>=bar <span>[[foo]]</span>
18840 </p><p>[[bar <span>[[foo]]</span>
18841 </p><p>]]bar <span>[[foo]]</span>
18842 </p><p>=bar <span>foo]]</span>=
18846 #### ----------------------- PRE --------------------------
18847 #### 1. Leading whitespace in SOL context should be escaped
18848 #### ------------------------------------------------------
18850 1. Leading whitespace in SOL context should be escaped
18854 <nowiki> </nowiki>a
18856 <nowiki> </nowiki> a
18858 <nowiki> </nowiki>a(tab)
18860 <nowiki> </nowiki> a
18862 <nowiki> </nowiki> a
18865 <nowiki> </nowiki>b
18868 <nowiki> </nowiki>b
18871 <nowiki> </nowiki> b
18877 <p><!--cmt--> a</p>
18886 #### --------------- Behavior Switches --------------------
18888 1. Valid behavior switches should be escaped
18892 <nowiki>__TOC__</nowiki>
18898 2. Invalid behavior switches should not be escaped
18909 #### --------------- HTML tags ---------------
18912 #### 3. multi-line html tag
18913 #### 4. extension tags
18914 #### -----------------------------------------
18920 <a href="http://google.com">google</a>
18922 <a href="http://google.com">google</a>
18928 <nowiki><div>foo</div>
18929 <div style="color:red">foo</div></nowiki>
18931 <p><div>foo</div>
18932 <div style="color:red">foo</div>
18937 3. multi-line html tag
18952 <nowiki><ref>foo</ref></nowiki>
18954 <nowiki><ref>bar</nowiki>
18956 baz<nowiki></ref></nowiki>
18958 <p><ref>foo</ref>
18959 </p><p><ref>bar
18960 </p><p>baz</ref>
18964 #### --------------- Others ---------------
18968 <nowiki>foo</nowiki>
18970 <p><nowiki>foo</nowiki>
18974 ## The quote-char in the input is necessary for triggering the bug
18976 (Bug 52035) Nowiki-escaping should not get tripped by " :" in text
18978 parsoid=wt2wt,html2wt
18987 Tag-like HTML structures are passed through as text
19009 </p><p>1<d e>f
19014 # This was a bug in the PHP parser (see bug 17663 and its dups,
19015 # https://bugzilla.wikimedia.org/show_bug.cgi?id=17663)
19017 Tag names followed by punctuation should not be recognized as tags
19021 <p><s.ome> text
19026 HTML tag with necessary entities in attributes
19028 <span title="&amp;">foo</span>
19030 <p><span title="&amp;">foo</span>
19035 HTML tag with 'unnecessary' entity encoding in attributes
19037 <span title="&">foo</span>
19039 <p><span title="&">foo</span>
19044 HTML tag with broken attribute value quoting
19046 <span title="Hello world>Foo</span>
19048 <p><span>Foo</span>
19053 Parsoid-only: HTML tag with broken attribute value quoting
19057 <span title="Hello world>Foo</span>
19059 <p><span title="Hello world">Foo</span>
19064 Table with broken attribute value quoting
19067 | title="Hello world|Foo
19078 Table with broken attribute value quoting on consecutive lines
19081 | title="Hello world|Foo
19082 | style="color:red|Bar
19095 Parsoid-only: Table with broken attribute value quoting on consecutive lines
19100 | title="Hello world|Foo
19101 | style="color:red|Bar
19106 <td title="Hello world">Foo
19107 </td><td style="color: red">Bar
19108 </td></tr></tbody></table>
19113 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
19123 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
19133 Accept empty td cell attribute
19136 | align="center" | foo || |
19141 <td align="center"> foo </td>
19148 Non-empty attributes in th-cells
19151 ! Foo !! style="color: red" | Bar
19157 <th style="color: red"> Bar
19163 Accept empty attributes in th-cells
19178 Empty table rows go away
19199 ### Parsoid-centric tests for testing RTing of inter-element separators
19200 ### Edge cases not tested by existing parser tests and specific to
19201 ### Parsoid-specific serialization strategies.
19205 RT-ed inter-element separators should be valid separators
19218 Trailing newlines in a deep dom-subtree that ends a wikitext line should be migrated out
19219 (Parsoid-only since PHP parser relies on Tidy for correct output)
19235 Empty TD followed by TD with tpl-generated attribute
19240 |{{echo|style='color:red'}}|foo
19254 Indented table with an empty td
19273 Empty TR followed by a template-generated TR
19274 (Parsoid-specific since PHP parser doesn't handle this mixed tbl-wikitext)
19280 {{echo|<tr><td>foo</td></tr>}}
19286 <tr about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<tr><td>foo</td></tr>"}},"i":0}}]}'>
19291 ## PHP and parsoid output differ for this, and since this is primarily
19292 ## for testing Parsoid's serializer, marking this Parsoid only
19294 Empty TR followed by mixed-ws-comment line should RT correctly
19310 <!--c--> </tr><!--d-->
19316 Multi-line image caption generated by templates with/without trailing newlines
19320 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}]]
19321 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}\n\n]]
19323 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=Special:Upload&wpDestFile=Foo.jpg" class="new" title="File:Foo.jpg">File:Foo.jpg</a> <div class="thumbcaption">foo\nA\nB\nC</div></div></div>
19324 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/index.php?title=Special:Upload&wpDestFile=Foo.jpg" class="new" title="File:Foo.jpg">File:Foo.jpg</a> <div class="thumbcaption">foo\nA\nB\nC\n\n</div></div></div>
19329 New element inserted (without intervening newlines) after an old sol-transparent node should serialize correctly
19333 <includeonly>foo</includeonly>
19340 <meta typeof="mw:Includes/IncludeOnly" data-parsoid='{"src":"<includeonly>foo</includeonly>"}'/><meta typeof="mw:Includes/IncludeOnly/End" data-parsoid='{"src":""}'/><p>new para</p>
19342 <link rel="mw:PageProp/Category" href="./Category:Foo" data-parsoid=''/><h1>new heading</h1>
19345 ## PHP emits broken html for this, and since this is primarily
19346 ## a Parsoid serializer test, marking this Parsoid only
19348 Improperly nested inline or quotes tags with whitespace in between
19352 <span> <s>x</span> </s>
19355 <p><span> <s>x</s></span><s> </s>
19356 <b> <i>x</i></b><i> </i>
19361 Encapsulate protected attributes from wt
19365 <div typeof="mw:placeholder stuff" data-parsoid="weird" data-parsoid-other="no" about="time" rel="mw:true">foo</div>
19367 <body><div data-x-typeof="mw:placeholder stuff" data-x-data-parsoid="weird" data-x-data-parsoid-other="no" data-x-about="time" data-x-rel="mw:true">foo</div>
19371 ## Currently the p-wrapper is fragile in how it adds / removes transformations.
19372 ## Having nested or stray pre tags results in the attempt to add duplicates,
19373 ## causing an assertion fail. This test tries to prevent that situation.
19375 Ensure ParagraphWrapper can deal with stray closing pre tags
19385 1. Ensure fostered text content is wrapped in spans
19389 <table>hi</table><table>ho</table>
19398 2. Ensure fostered text content is wrapped in spans (traps regressions around fostered marker on the span getting lost)
19400 parsoid=wt2html,wt2wt
19407 <span> || ||</span>
19416 Encapsulation properly handles null DSR information from foster box
19418 parsoid=wt2html,wt2wt
19420 {{echo|<table>foo<tr><td>bar</td></tr></table>}}
19422 <span typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"
19425 <td>bar</td></tr></table>"}},"i":0}}]}">foo</span>
19429 <td>bar</td></tr></tbody></table>
19433 1. Encapsulate foster-parented transclusion content
19435 parsoid=wt2wt,wt2html
19437 <table>{{echo|foo<tr><td>bar</td></tr>}}</table>
19439 <span typeof="mw:Transclusion" data-mw="{"parts":["
19440 <table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo
19442 <td>bar</td></tr>"}},"i":0}},"</table>"]}">foo</span>
19446 <td>bar</td></tr></tbody></table>
19450 2. Encapsulate foster-parented transclusion content
19452 parsoid=wt2wt,wt2html
19454 <table><div>{{echo|foo}}</div><tr><td>bar</td></tr></table>
19456 <div typeof="mw:Transclusion" data-mw="{"parts":["
19458 <div>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo"}},"i":0}},"</div>
19460 <td>bar</td></tr></table>"]}">foo</div>
19464 <td>bar</td></tr></tbody></table>
19468 3. Encapsulate foster-parented transclusion content
19470 parsoid=wt2wt,wt2html
19472 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
19474 <div typeof="mw:Transclusion" data-mw="{"parts":["
19477 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div>
19479 <td>"}},"i":0}},"bar</td></tr></table>"]}">
19484 <td>bar</td></tr></tbody></table>
19488 4. Encapsulate foster-parented transclusion content
19490 parsoid=wt2wt,wt2html
19492 <table><div><p>{{echo|foo</p></div><tr><td>}}bar</td></tr></table>
19494 <div typeof="mw:Transclusion" data-mw="{"parts":["
19497 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div>
19499 <td>"}},"i":0}},"bar</td></tr></table>"]}">
19504 <td>bar</td></tr></tbody></table>
19508 5. Encapsulate foster-parented transclusion content
19510 parsoid=wt2wt,wt2html
19512 <table><tr><td><div><p>{{echo|foo</p></div></td>foo}}</tr></table>
19514 <span typeof="mw:Transclusion" data-mw="{"parts":["
19519 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div></td>foo"}},"i":0}},"</tr></table>"]}">foo</span>
19525 <p>foo</p></div></td></tr></tbody></table>
19529 6. Encapsulate foster-parented transclusion content
19531 parsoid=wt2wt,wt2html
19533 <table><tr><td><div><p>{{echo|foo</p></div></td>foo</tr></table>}}<p>ok</p>
19535 <span typeof="mw:Transclusion" data-mw="{"parts":["
19540 <p>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"foo</p></div></td>foo</tr></table>"}},"i":0}}]}">foo</span>
19546 <p>foo</p></div></td></tr></tbody></table>
19551 7. Encapsulate foster-parented transclusion content
19553 parsoid=wt2wt,wt2html
19555 <table>{{echo|<p>foo</p>}}<td>bar</td></table>
19557 <p typeof="mw:Transclusion" data-mw="{"parts":["
19558 <table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"
19559 <p>foo</p>"}},"i":0}},"
19560 <td>bar</td></table>"]}">foo</p>
19564 <td>bar</td></tr></tbody></table>
19568 8. Encapsulate foster-parented transclusion content
19570 parsoid=wt2wt,wt2html
19573 }}{|{{echo|style='color:red'}}
19578 <p typeof="mw:Transclusion" data-mw="{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"a\n"}},"i":0}}]}">a</p><span typeof="mw:Transclusion" data-mw="{"parts":["{|",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"style":{"wt":"'color:red'"}},"i":0}},"\n|-\n|b\n|}"]}">{{{1}}}</span>
19582 <td>b</td></tr></tbody></table>
19586 9. Encapsulate foster-parented transclusion content
19588 parsoid=wt2wt,wt2html
19590 <table>{{echo|hi</table>hello}}
19592 <span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":["<table>",{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"hi</table>hello"}},"i":0}}]}' data-parsoid='{"fostered":true,"autoInsertedEnd":true,"autoInsertedStart":true,"pi":[[{"k":"1","spc":["","","",""]}]]}'>hi</span>
19593 <table about="#mwt2" data-parsoid='{"stx":"html"}'></table><span about="#mwt2" data-parsoid="{}">hello</span>
19597 Table in fosterable position
19599 parsoid=wt2html,wt2wt
19608 <div about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"OpenTable","href":"./Template:OpenTable"},"params":{},"i":0}},"\n<div>"]}' data-parsoid='{"stx":"html","autoInsertedEnd":true,"pi":[[]]}'></div><span about="#mwt1" data-parsoid="{}">
19610 <table about="#mwt1" data-parsoid='{"autoInsertedEnd":true}'></table>
19617 Support <object> element with .data attribute
19621 <object data="test.swf"></object>
19623 <object data="test.swf"></object>
19626 # -----------------------------------------------------------------
19627 # The following section of tests are primarily to spec requirements
19628 # around serialization of new/edited content.
19630 # All these tests are marked Parsoid html2wt and html2html only
19631 # ----------------------------------------------------------------
19634 Image: Modifying size of an image (1)
19637 "modes": ["wt2wt"],
19639 ["img[height]", "attr", "height", "22"],
19640 ["img[width]", "attr", "width", "200"]
19644 [[Image:Foobar.jpg|230x230px]]
19646 [[Image:Foobar.jpg|200x200px]]
19650 Image: Modifying size of an image (2)
19653 "modes": ["wt2wt"],
19655 ["img[height]", "attr", "height", "100"],
19656 ["img[width]", "attr", "width", "500"]
19660 [[Image:Foobar.jpg|230x230px]]
19662 [[Image:Foobar.jpg|500x500px]]
19665 # Change in size is ignored so long as class='mw-default-size'
19667 Image: Modifying size of an image (3)
19670 "modes": ["wt2wt"],
19672 ["figure[class]", "removeClass", "mw-default-size"],
19673 ["figure img", "attr", "height", "19"],
19674 ["figure img", "attr", "width", "170"]
19678 [[Image:Foobar.jpg|thumb]]
19680 [[Image:Foobar.jpg|thumb|170x170px]]
19684 Image: Modifying alignment of an image (bug 48665)
19687 "modes": ["wt2wt"],
19689 ["figure[class]", "removeClass", "mw-halign-right"],
19690 ["figure[class]", "addClass", "mw-halign-left"]
19694 [[Image:Foobar.jpg|thumb|caption|right]]
19696 [[Image:Foobar.jpg|thumb|caption|left]]
19700 Image: Modifying mw-default-size of an frameless image (bug 62805)
19703 "modes": ["wt2wt"],
19705 ["figure.mw-default-size", "removeClass", "mw-default-size"]
19709 [[Image:Foobar.jpg|frameless|right]]
19711 [[Image:Foobar.jpg|frameless|right|220x220px]]
19715 Image: Modifying valign of an image (bug 49221)
19718 "modes": ["wt2wt"],
19720 ["*[typeof=\"mw:Image\"]", "removeClass", "mw-valign-middle"],
19721 ["*[typeof=\"mw:Image\"]", "addClass", "mw-valign-text-top"]
19725 [[File:Foobar.jpg|20px|middle]]
19727 [[File:Foobar.jpg|20px|text-top]]
19731 Image: Modifying alt attribute of an image (bug 56400)
19734 "modes": ["wt2wt"],
19736 ["img[alt]", "attr", "alt", "some alternate edited text"]
19740 [[File:Foobar.jpg|thumb|some caption|alt=some alternate text]]
19742 [[File:Foobar.jpg|thumb|some caption|alt=some alternate edited text]]
19746 Image: Modifying caption of an image
19749 "modes": ["wt2wt"],
19751 ["figcaption", "text", "new caption"]
19755 [[Image:Foobar.jpg|thumb|original caption]]
19757 [[Image:Foobar.jpg|thumb|new caption]]
19761 Image: empty alt attribute (bug 48924)
19765 [[File:Foobar.jpg|thumb|alt=|bar]]
19767 <figure class="mw-default-size" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"thumbnail","ak":"thumb"},{"ck":"alt","ak":"alt="},{"ck":"caption","ak":"bar"}]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"}}'><img alt="" resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/220px-Foobar.jpg" height="25" width="220" data-parsoid='{"a":{"alt":"","resource":"./File:Foobar.jpg","height":"25","width":"220"},"sa":{"alt":"alt=","resource":"File:Foobar.jpg"}}'/></a><figcaption>bar</figcaption></figure>
19771 #Image: new attributes should be serialized in wiki's language for RTL languages (bug 51852)
19776 #[[Imagen:Foobar.jpg|derecha|miniaturadeimagen]]
19778 #<figure class="mw-default-size mw-halign-right" typeof="mw:Image/Thumb"><a href="Imagen:Foobar.jpg"><img resource="./Imagen:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="20" width="180"/></a></figure>
19782 Image: Block level image should have \n before and after
19787 [[File:Foobar.jpg|right|thumb|150x150px]]
19790 <p>123</p><figure typeof="mw:Image/Thumb" class="mw-halign-right"><a href="./File:Foobar.png"><img src="http://192.168.142.128/mw/images/thumb/b/bc/Foobar.png/131px-Foobar.png" width="131" height="150" resource="./File:Foobar.png" data-parsoid='{"a":{"resource":"./File:Foobar.png","width":"131"},"sa":{"resource":"File:Foobar.png","width":"150"}}'></a></figure><p>456</p>
19794 Image: New block level image should have \n before and after (existing
19800 [[File:Foobar.jpg|right|thumb|150x150px]]
19803 <p data-parsoid='{"dsr":[0,3,0,0]}'>123</p>
19804 <figure class="mw-halign-right" typeof="mw:Image/Thumb" data-parsoid='{"optList":[{"ck":"right","ak":"right"},{"ck":"thumbnail","ak":"thumb"},{"ck":"width","ak":"150x150px"}],"dsr":[4,45,2,2]}'><a href="./File:Foobar.jpg" data-parsoid='{"a":{"href":"./File:Foobar.jpg"},"dsr":[6,43,null,null]}'><img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/150px-Foobar.jpg" height="17" width="150" data-parsoid='{"a":{"resource":"./File:Foobar.jpg","height":"17","width":"150"},"sa":{"resource":"File:Foobar.jpg"}}'/></a></figure>
19805 <p data-parsoid='{"dsr":[46,49,0,0]}'>456</p>
19809 Image: upright option (parsoid)
19813 [[File:Foobar.jpg|thumb|upright|caption]]
19814 [[File:Foobar.jpg|thumb|upright=0.5|caption]]
19815 [[File:Foobar.jpg|thumb|500x500px|upright=0.5|caption]]
19817 <figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="19" width="170"/></a><figcaption>caption</figcaption></figure><figure class="mw-default-size" typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="19" width="170"/></a><figcaption>caption</figcaption></figure><figure typeof="mw:Image/Thumb"><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="57" width="500"/></a><figcaption>caption</figcaption></figure>
19821 Image: upright option is ignored on inline and frame images (parsoid)
19825 [[File:Foobar.jpg|500x500px|upright=0.5|caption]]
19827 <p><span typeof="mw:Image" data-mw='{"caption":"caption"}'><a href="File:Foobar.jpg"><img resource="./File:Foobar.jpg" src="//example.com/images/3/3a/Foobar.jpg" height="57" width="500"/></a></span></p>
19831 Image: from basic HTML (1)
19835 <span typeof="mw:Image">
19836 <img src="File:Foobar.jpg" width=100 height=100 alt="Alt">
19839 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
19843 Image: from basic HTML (2)
19847 <img src="File:Foobar.jpg" width=100 height=100 alt="Alt">
19849 [[File:Foobar.jpg|link=|alt=Alt|100x100px]]
19853 Image: from basic HTML (3)
19857 <a href="Main"><img src="File:Foobar.jpg" width=100 height=100 alt="Alt"></a>
19859 [[File:Foobar.jpg|link=Main|alt=Alt|100x100px]]
19863 Image: from basic HTML (4)
19867 <img src="File:Foobar.jpg">
19869 [[File:Foobar.jpg|link=]]
19873 Lists: Serialize correctly even when list content is wrapped in p-tags (like VE does)
19880 <li><p>foo</p></li>
19885 Lists: Serialize correctly even when list tags has unneeded whitespace between tags
19891 <ul> <li>foo</li></ul>
19895 Don't strip leading whitespace when handling indent-pre suppressing tags
19903 '''This is very bold of you!'''
19907 indented cell (no pre-wrapping!)
19914 <tr><td> indented row</td></tr>
19917 <b>This is very bold of you!</b>
19920 indented cell (no pre-wrapping!)
19928 Strip leading whitespace when handling indent-pre inducing tags
19960 Lists: Add space after bullets
19966 * <span> baz</span>
19971 <li><span> baz</span></li>
19976 Lists: Dont insert newlines in a serialized list item.
19983 <ul><li>a<br>b</li><li>c</li></ul>
19987 Headings: Add space before/after == (Bug 51744)
19997 == <span> baz</span> ==
20002 <h2><span> baz</span></h2>
20006 Parsoid: Serialize positional parameters with = in them as named parameter
20012 {{echo|1 = f=oo|2 = bar}}
20014 <!--Orig params with data-parsoid has heuristics for handling = chars-->
20015 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
20016 {{echo|<nowiki>f=oo</nowiki>|bar}}
20018 <p about="#mwt1" typeof="mw:Transclusion"
20019 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}},"i":0}}]}'>foo</p>
20021 <p about="#mwt1" typeof="mw:Transclusion"
20022 data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}, "2":{"wt":"bar"}},"i":0}}]}'>foo</p>
20024 <!--Orig params with data-parsoid has heuristics for handling = chars-->
20025 <!--FIXME: But maybe the heuristic needs fixing to apply to new params as well-->
20026 <p data-parsoid='{"pi":[[{"k":"1","spc":["","","",""]},{"k":"2","spc":["","","",""]}]]}' about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"},"2":{"wt":"bar"}},"i":0}}]}'>foo</p>
20030 Parsoid: Correctly serialize block-node children when they are a combination of text and p-nodes
20046 <div>a<p>b</p></div>
20055 Substrings resembling wikitext in hrefs should not get nowiki escapes
20061 <a rel="mw:WikiLink" href="./Foo''bar''baz">Foo''bar''baz</a>
20064 #-----------------------------
20065 # I/B quote minimization tests
20066 #-----------------------------
20069 1. I/B quote minimization: wikitext-only tags should be combined
20089 <p><i>A</i><i>B</i></p>
20090 <p><b>A</b><b>B</b></p>
20091 <p><i>A</i><b><i>B</i></b></p>
20092 <p><b>A</b><i><b>B</b></i></p>
20093 <p><b>A</b><i><b>B</b><b>C</b></i><b>D</b></p>
20094 <p><i><b>A</b></i><i><b>B</b></i></p>
20095 <p><i><b>A</b></i><b><i>B</i></b></p>
20096 <p><b><i>A</i></b><i><b>B</b></i></p>
20100 2. I/B quote minimization: wikitext and html tags should not be combined
20106 ''A'''''<i>B</i>'''
20108 <p><i>A</i><i data-parsoid='{"stx":"html"}'>B</i></p>
20109 <p><i>A</i><b><i data-parsoid='{"stx":"html"}'>B</i></b></p>
20113 3. I/B quote minimization: templated content stops minimization
20117 ''A''{{echo|''B''}}
20119 ''A''{{echo|'''''B'''''}}
20121 <p><i>A</i><i about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"''B''"}},"i":0}}]}'>B</i>
20122 <p><i>A</i><b about="#mwt1" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"'''''B'''''"}},"i":0}}]}'><i>B</i></b>
20126 4. I/B quote minimization: new content should be mimimized with adjacent old content
20136 <p><i>A</i><i data-parsoid='{}'>B</i></p>
20137 <p><b data-parsoid='{}'>A</b><b>B</b></p>
20138 <p><i>A</i><b data-parsoid='{}'><i data-parsoid='{}'>B</i></b></p>
20141 #------------------------------------
20142 # End of I/B quote minimization tests
20143 #------------------------------------
20146 Bug 54262: New entities
20152 <span typeof="mw:Entity"> </span>
20155 ## Note that there is no wikitext output for 'unknownproperty' ##
20156 ## Unknown magic words are silently dropped ##
20171 __NOCONTENTCONVERT__
20173 <meta property='mw:PageProp/toc' />
20174 <meta property='mw:PageProp/notoc' />
20175 <meta property='mw:PageProp/forcetoc' />
20176 <meta property='mw:PageProp/index' />
20177 <meta property='mw:PageProp/noindex' />
20178 <meta property='mw:PageProp/nogallery' />
20179 <meta property='mw:PageProp/noeditsection' />
20180 <meta property='mw:PageProp/notitleconvert' />
20181 <meta property='mw:PageProp/nocontentconvert' />
20182 <meta property='mw:PageProp/unknownproperty' />
20186 Consecutive <pre>s should not get merged
20188 parsoid=html2wt,html2html
20204 <pre>a</pre><pre>b</pre>
20218 Edited ISBN links not serializable as ISBN links should serialize as wikilinks
20222 [[Special:BookSources/1234567890|ISBN 1234567895]]
20224 <a rel="mw:ExtLink" href="./Special:BookSources/1234567890">ISBN 1234567895</a>
20228 Edited RFC links not serializable as RFC links should serialize as extlinks
20232 [//tools.ietf.org/html/rfc123 New RFC]
20234 <a href="//tools.ietf.org/html/rfc123" rel="mw:ExtLink">New RFC</a>
20238 Edited PMID links not serializable as PMID links should serialize as extlinks
20242 [//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract New PMID]
20244 <a href="//www.ncbi.nlm.nih.gov/pubmed/123?dopt=Abstract" rel="mw:ExtLink">New PMID</a>
20248 Edited Redirect link should emit a non-piped wikitext link
20254 <link rel="mw:PageProp/redirect" href="Bar" data-parsoid='{"src":"#REDIRECT ","a":{"href":"./Foo"},"sa":{"href":"Foo"}}'>
20257 # -----------------------------------------------------------------
20258 # End of section for Parsoid-only html2wt tests for serialization
20260 # -----------------------------------------------------------------
20267 Try for 100% code coverage