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-only test (not run by PHP parser)
25 # php php-only test (not run by the parsoid parser)
26 # showtitle make the first line the title
27 # comment run through Linker::formatComment() instead of main parser
28 # local format section links in edit comment text as local links
30 # You can also set the following parser properties via test options:
31 # wgEnableUploads, wgAllowExternalImages, wgMaxTocLevel,
32 # wgLinkHolderBatchSize, wgRawHtml
34 # For testing purposes, temporary articles can created:
35 # !!article / NAMESPACE:TITLE / !!text / ARTICLE TEXT / !!endarticle
36 # where '/' denotes a newline.
38 # This is the standard article assumed to exist.
63 MediaWiki:bad image list
65 * [[File:Bad.jpg]] except [[Nasty page]]
99 Template:echo_with_span
105 Template:echo_with_div
117 Template:table_attribs
120 |</noinclude>style="color: red"| Foo
126 {{table_attribs}} || Bar || Baz
130 Template:image_attribs
133 [[File:foobar.jpg|</noinclude>right|Caption text<noinclude>]]</noinclude>
161 This is a simple paragraph.
163 <p>This is a simple paragraph.
168 Paragraphs with extra newline spacing
191 Paragraphs with newline spacing with comment lines in between
199 <!--foo--><!--More than 1 comment, still stripped-->
203 <!--foo--> <!----> <!-- bar -->
264 Paragraphs with newline spacing with non-empty white-space lines in between
291 Paragraphs with newline spacing with non-empty mixed comment and white-space lines in between
299 <!--foo--><!--More than 1 comment doesn't disable stripping of this line!-->
338 Extra newlines: More paragraphs with indented comment
353 Extra newlines followed by heading
368 <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>
369 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
372 <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>
377 Extra newlines between heading and content are swallowed
385 <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>
386 <p><a href="/index.php?title=A&action=edit&redlink=1" class="new" title="A (page does not exist)">a</a>
393 http://fr.wikipedia.org/wiki/🍺
394 <!-- EasterEgg we love beer, better be able be able to link to it -->
396 <p><a rel="nofollow" class="external free" href="http://fr.wikipedia.org/wiki/🍺">http://fr.wikipedia.org/wiki/🍺</a>
416 * plain''italic''plain
417 * plain''italic''plain''italic''plain
418 * plain'''bold'''plain
419 * plain'''bold'''plain'''bold'''plain
420 * plain''italic''plain'''bold'''plain
421 * plain'''bold'''plain''italic''plain
422 * plain''italic'''bold-italic'''italic''plain
423 * plain'''bold''bold-italic''bold'''plain
424 * plain'''''bold-italic'''italic''plain
425 * plain'''''bold-italic''bold'''plain
426 * plain''italic'''bold-italic'''''plain
427 * plain'''bold''bold-italic'''''plain
428 * plain l'''italic''plain
429 * plain l''''bold''' plain
432 </li><li> plain<i>italic</i>plain
433 </li><li> plain<i>italic</i>plain<i>italic</i>plain
434 </li><li> plain<b>bold</b>plain
435 </li><li> plain<b>bold</b>plain<b>bold</b>plain
436 </li><li> plain<i>italic</i>plain<b>bold</b>plain
437 </li><li> plain<b>bold</b>plain<i>italic</i>plain
438 </li><li> plain<i>italic<b>bold-italic</b>italic</i>plain
439 </li><li> plain<b>bold<i>bold-italic</i>bold</b>plain
440 </li><li> plain<i><b>bold-italic</b>italic</i>plain
441 </li><li> plain<b><i>bold-italic</i>bold</b>plain
442 </li><li> plain<i>italic<b>bold-italic</b></i>plain
443 </li><li> plain<b>bold<i>bold-italic</i></b>plain
444 </li><li> plain l'<i>italic</i>plain
445 </li><li> plain l'<b>bold</b> plain
450 # this example taken from the simple/Moon article
452 Italics and possessives
454 obtained by ''[[Lunar Prospector]]'''s gamma-ray spectrometer
456 <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
461 ### 2-quote opening sequence tests
464 Italics and bold: 2-quote opening sequence: (2,2)
474 Italics and bold: 2-quote opening sequence: (2,3)
484 Italics and bold: 2-quote opening sequence: (2,4)
494 Italics and bold: 2-quote opening sequence: (2,5) (php)
503 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
505 Italics and bold: 2-quote opening sequence: (2,5) (parsoid)
517 ### 3-quote opening sequence tests
521 Italics and bold: 3-quote opening sequence: (3,2)
531 Italics and bold: 3-quote opening sequence: (3,3)
541 Italics and bold: 3-quote opening sequence: (3,4)
551 Italics and bold: 3-quote opening sequence: (3,5) (php)
560 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
562 Italics and bold: 3-quote opening sequence: (3,5) (parsoid)
574 ### 4-quote opening sequence tests
578 Italics and bold: 4-quote opening sequence: (4,2)
588 Italics and bold: 4-quote opening sequence: (4,3)
598 Italics and bold: 4-quote opening sequence: (4,4)
608 Italics and bold: 4-quote opening sequence: (4,5) (php)
617 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
619 Italics and bold: 4-quote opening sequence: (4,5) (parsoid)
625 <p>'<b>foo<i></i></b>
631 ### 5-quote opening sequence tests
635 Italics and bold: 5-quote opening sequence: (5,2) (php)
644 # Parsoid reverses the nesting order, compared to the PHP parser
646 Italics and bold: 5-quote opening sequence: (5,2) (parsoid)
658 Italics and bold: 5-quote opening sequence: (5,3)
668 Italics and bold: 5-quote opening sequence: (5,4)
672 <p><i><b>foo'</b></i>
678 Italics and bold: 5-quote opening sequence: (5,5)
687 ### multiple quote sequences in a line
690 Italics and bold: multiple quote sequences: (2,4,2)
694 <p><i>foo'<b>bar</b></i>
700 Italics and bold: multiple quote sequences: (2,4,3)
704 <p><i>foo'<b>bar</b></i>
710 Italics and bold: multiple quote sequences: (2,4,4)
714 <p><i>foo'<b>bar'</b></i>
720 Italics and bold: multiple quote sequences: (3,4,2) (php)
729 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
731 Italics and bold: multiple quote sequences: (3,4,2) (parsoid)
737 <p><b>foo'</b>bar<i></i>
743 Italics and bold: multiple quote sequences: (3,4,3) (php)
752 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
754 Italics and bold: multiple quote sequences: (3,4,3) (parsoid)
760 <p><b>foo'</b>bar<b></b>
765 ### other quote tests
768 Italics and bold: other quote tests: (2,3,5)
770 ''this is about '''foo's family'''''
772 <p><i>this is about <b>foo's family</b></i>
778 Italics and bold: other quote tests: (2,(3,3),2)
780 ''this is about '''foo's''' family''
782 <p><i>this is about <b>foo's</b> family</i>
788 Italics and bold: other quote tests: (3,2,3,2)
790 '''this is about ''foo'''s family''
792 <p><b>this is about <i>foo</i></b><i>s family</i>
797 # The Parsoid team believes the PHP parser's output on this test is wrong.
798 # It only checks for convert-to-bold-on-single-character-word when the word
799 # matches with a bold tag ("'''") that is *odd* in the list of quote tokens.
800 # This means that the bold token in position 2 (0-indexed) gets converted by
801 # parsoid, but doesn't get changed by the PHP parser.
803 Italics and bold: other quote tests: (3,2,3,3) (php)
807 '''this is about ''foo'''s family'''
809 <p>'<i>this is about </i>foo<b>s family</b>
812 # This is the output the Parsoid team believes to be correct.
814 Italics and bold: other quote tests: (3,2,3,3) (parsoid)
818 '''this is about ''foo'''s family'''
820 <p><b>this is about <i>foo'</i>s family</b>
826 Italics and bold: other quote tests: (3,(2,2),3)
828 '''this is about ''foo's'' family'''
830 <p><b>this is about <i>foo's</i> family</b>
836 Italicized possessive
838 The ''[[Main Page]]'''s talk page.
840 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
845 Parsoid only: Quote balancing context should be restricted to td/th cells on the same wikitext line
846 (Requires tidy for PHP parser output to be fixed up)
848 parsoid=wt2html,wt2wt
856 <tbody><tr><th><i>a</i></th><th><i>b</i></th>
857 <td><i>a</i></td><td><i>b</i></td></tr>
866 Non-html5 tags should be accepted
868 <center>''foo''</center>
871 <strike>''foo''</strike>
874 <center><i>foo</i></center>
875 <p><big><i>foo</i></big>
876 <font><i>foo</i></font>
877 <strike><i>foo</i></strike>
883 <wbr> is valid wikitext (bug 52468)
891 # <strike> is HTML4, <s> is HTML4/5.
893 <s> or <strike> for strikethrough
895 <strike>strike</strike>
899 <p><strike>strike</strike>
905 Non-word characters don't terminate tag names (bug 17663, 40670, 52022)
907 <b→> doesn't work! </b>
909 <bä> doesn't work! </b>
911 <boo> works fine </b>
919 <p><b→> doesn't work! </b>
920 </p><p><bä> doesn't work! </b>
921 </p><p><boo> works fine </b>
922 </p><p><s.foo>foo</s>
923 </p><p><s.foo>s.foo</s.foo>
924 </p><p><sub-ID#1>
929 ### Special characters
933 Bare pipe character (bug 52363)
942 Bare pipe character from a template (bug 52363)
951 ### <nowiki> test cases
955 <nowiki> unordered list
957 <nowiki>* This is not an unordered list item.</nowiki>
959 <p>* This is not an unordered list item.
966 <nowiki>Lorem ipsum dolor
987 :There is not nowiki.
988 :There is <nowiki>nowiki</nowiki>.
990 #There is not nowiki.
991 #There is <nowiki>nowiki</nowiki>.
993 *There is not nowiki.
994 *There is <nowiki>nowiki</nowiki>.
996 <dl><dd>There is not nowiki.
997 </dd><dd>There is nowiki.
999 <ol><li>There is not nowiki.
1000 </li><li>There is nowiki.
1002 <ul><li>There is not nowiki.
1003 </li><li>There is nowiki.
1009 Entities inside <nowiki>
1011 <nowiki><</nowiki>
1018 Entities inside template parameters
1024 <p><span typeof="mw:Transclusion mw:Entity" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&ndash;"}},"i":0}'>–</span>
1032 Comments and Indent-Pre
1034 <!-- comment 1 --> asdf
1036 <!-- comment 1 --> asdf
1039 <!-- comment 1 --> asdf
1040 <!-- comment 2 -->xyz
1042 <!-- comment 1 --> asdf
1043 <!-- comment 2 --> xyz
1099 asdf<!-- comment 1 -->jkl
1109 <!-- foo --> b <!-- bar -->
1123 <!-- returns a single newline, not nothing, since the newline after > is not stripped -->
1129 Comment semantics and delimiters
1131 <!-- --><!----><!-----><!------>
1137 Comment semantics and delimiters, redux
1139 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
1140 -- foo -- funky huh? ... -->
1146 Comment semantics and delimiters: directors cut
1148 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
1149 everything starting with < followed by !-- until the first -- and > we see,
1150 that wouldn't be valid XML however, since in XML -- has to terminate a comment
1158 Comment semantics: nesting
1160 <!--<!-- no, we're not going to do anything fancy here -->-->
1167 Comment semantics: unclosed comment at end
1169 <!--This comment will run out to the end of the document
1175 Comment in template title
1184 Comment on its own line post-expand
1196 Comment on its own line post-expand with non-significant whitespace
1208 ### paragraph wrapping tests
1222 Block tag on one line
1234 Block tag on both lines
1246 Multiple lines without block tags
1264 Empty lines between lines with block tags
1294 ### Preformatted text
1303 And a [[Main Page|link]]
1309 And a <a href="/wiki/Main_Page" title="Main Page">link</a>
1314 Ident preformatting with inline content
1325 <pre> with <nowiki> inside (compatibility with 1.6 and earlier)
1342 Regression with preformatted in <center>
1355 # Expected output in the following test is not really expected (there should be
1356 # <pre> in the output) -- it's only testing for well-formedness.
1358 Bug 6200: Preformatted in <blockquote>
1371 <pre> with attributes (bug 3202)
1373 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1375 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1380 <pre> with width attribute (bug 3202)
1382 <pre width="8">Narrow screen goodies</pre>
1384 <pre width="8">Narrow screen goodies</pre>
1389 <pre> with forbidden attribute (bug 3202)
1391 <pre width="8" onmouseover="alert(document.cookie)">Narrow screen goodies</pre>
1393 <pre width="8">Narrow screen goodies</pre>
1398 Entities inside <pre>
1407 <pre> with forbidden attribute values (bug 3202)
1409 <pre width="8" style="border-width: expression(alert(document.cookie))">Narrow screen goodies</pre>
1411 <pre width="8" style="/* insecure input */">Narrow screen goodies</pre>
1416 <nowiki> inside <pre> (bug 13238)
1424 <pre><nowiki><nowiki></nowiki>Foo<nowiki></nowiki></nowiki></pre>
1432 <pre><nowiki>Foo</nowiki></pre>
1437 <nowiki> and <pre> preference (first one wins)
1468 </pre> inside nowiki
1470 <nowiki></pre></nowiki>
1477 Templates: Indent-Pre: 1a. Templates that break a line should suppress <pre>
1485 Templates: Indent-Pre: 1b. Templates that break a line should suppress <pre>
1495 Templates: Indent-Pre: 1c: Wrapping should be based on expanded content
1507 Templates: Indent-Pre: 1d: Wrapping should be based on expanded content
1528 Templates: Indent-Pre: 1e. Wrapping should be based on expanded content
1532 {{echo| foo}}{{echo| bar}}
1537 {{echo|<!--cmt--> foo}}
1539 <!--cmt-->{{echo| foo}}
1541 {{echo|{{echo| }}bar}}
1559 Templates: Indent-Pre: 1f: Wrapping should be based on expanded content
1596 Templates: Single-line variant of parameter whitespace stripping test
1602 {{echo|{{echo| a}}}}
1604 {{echo|1={{echo| a}}}}
1617 Templates: Strip whitespace from named parameters, but not positional ones
1645 Templates: Dont strip whitespace from whitespace/comment-only arguments
1649 {{echo| <!--cmt--> }}
1656 Templates: Parsoid parameter escaping test 1
1660 {{echo|[foo]|{{echo|[bar]}}}}
1662 <p about="#mwt1" typeof="mw:Transclusion"
1663 data-mw="{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[foo]"},"2":{"wt":"{{echo|[bar]}}"}},"i":0}">[foo]</p>
1667 Parsoid: Pipes in external links in template parameter
1671 {{echo|[{{echo|http://example.com}} link]}}
1673 <p><a rel="mw:ExtLink" href="http://example.com" about="#mwt31" typeof="mw:Transclusion" data-mw="{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"[{{echo|http://example.com}} link]"}},"i":0}">link</a></p>
1677 Parsoid: pipe in transclusion parameter
1681 {{echo|http://foo.com/a|b}}
1683 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
1684 typeof="mw:Transclusion"
1685 data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"http://foo.com/a|b"}},"i":0}'>http://foo.com/a|b</a></p>
1689 Parsoid: Pipe in external link target and content in template parameter
1691 parsoid=html2wt,wt2wt
1693 {{echo|[http://foo.com/a|b a|b]}}
1695 <p><a rel="mw:ExtLink" href="http://foo.com/a|b" about="#mwt1"
1696 typeof="mw:Transclusion"
1697 data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},
1698 "params":{"1":{"wt":"[http://foo.com/a|b a|b]"}},"i":0}'>a|b</a></p>
1702 Templates: Dont escape already nowiki-escaped text in template parameters
1704 parsoid=html2wt,wt2wt
1706 {{echo|foo<nowiki>|</nowiki>bar}}
1707 {{echo|<nowiki><div></nowiki>}}
1708 {{echo|<nowiki></nowiki>}}
1710 <p><span about="#mwt1" typeof="mw:Transclusion" data-mw='{"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>
1711 <span typeof="mw:Transclusion mw:Nowiki" about="#mwt2" data-mw='{"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>
1712 <span typeof="mw:Transclusion mw:Nowiki" about="#mwt3" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<nowiki></nowiki>"}},"i":0}'></span>
1717 ### Parsoid-centric tests for testing RT edge cases for pre
1721 1a. Indent-Pre and Comments
1734 1b. Indent-Pre and Comments
1747 1c. Indent-Pre and Comments
1760 1d. Indent-Pre and Comments
1761 (Pre-handler currently cannot distinguish between comment/ws order and normalizes them to [comment,ws] order)
1774 2a. Indent-Pre and tables
1795 2b. Indent-Pre and tables
1811 2c. Indent-Pre and tables (bug 42252)
1828 3a. Indent-Pre and block tags (single-line html)
1836 <pre><span> foo </span>
1841 3b. Indent-Pre and block tags (pre-content on separate line)
1893 4. Multiple spaces at start-of-line
1912 5. White-space in indent-pre
1913 NOTE: the white-space char on 2nd line is significant
1926 6. Pre-blocks should extend across lines with leading WS even when there is no wrappable content
1949 7a. Indent-pre and category links
1951 parsoid=wt2html,wt2wt
1953 [[Category:foo]] <!-- No pre-wrapping -->
1954 {{echo| [[Category:foo]]}} <!-- No pre-wrapping -->
1956 <span typeof="mw:Transclusion"> </span>
1960 7b. Indent-pre and category links
1962 parsoid=wt2html,wt2wt
1965 [[Category:foo]] {{echo|b}}
1967 <pre> a <span typeof="mw:Transclusion">b</span>
1972 ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric)
1976 HTML-pre: 1. embedded newlines
2012 HTML-pre: 2: indented text
2025 HTML-pre: 3: other wikitext
2046 ### Definition lists
2053 <dl><dt> name </dt><dd> Definition
2059 Definition list for indentation only
2063 <dl><dd> Indented text
2069 Definition list with no space
2073 <dl><dt>name</dt><dd>Definition
2079 Definition list with URL link
2081 ; http://example.com/ : definition
2083 <dl><dt> <a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> </dt><dd> definition
2089 Definition list with bracketed URL link
2091 ;[http://www.example.com/ Example]:Something about it
2093 <dl><dt><a rel="nofollow" class="external text" href="http://www.example.com/">Example</a></dt><dd>Something about it
2099 Definition list with wikilink containing colon
2101 ; [[Help:FAQ]]: The least-read page on Wikipedia
2103 <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><dd> The least-read page on Wikipedia
2108 # At Brion's and JeLuF's insistence... :)
2110 Definition list with news link containing colon
2112 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
2114 <dl><dt> <a rel="nofollow" class="external free" href="news:alt.wikipedia.rox">news:alt.wikipedia.rox</a></dt><dd> This isn't even a real newsgroup!
2120 Malformed definition list with colon
2122 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
2124 <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
2130 Definition lists: colon in external link text
2132 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
2134 <dl><dt> <a rel="nofollow" class="external text" href="http://www.wikipedia2.org/">Wikipedia : The Next Generation</a></dt><dd> OK, I made that up
2140 Definition lists: colon in HTML attribute
2142 ;<b style="display: inline">bold</b>
2144 <dl><dt><b style="display: inline">bold</b>
2150 Definition lists: self-closed tag
2152 ;one<br/>two : two-line fun
2154 <dl><dt>one<br />two </dt><dd> two-line fun
2160 Bug 11748: Literal closing tags
2164 <dd>test test test test test</dd>
2166 <dd>test test test test test</dd>
2171 <dd>test test test test test</dd>
2173 <dd>test test test test test</dd>
2179 Definition and unordered list using wiki syntax nested in unordered list using html tags.
2182 ; term : description
2188 <dl><dt> term </dt><dd> description
2199 Definition list with empty definition and following paragraph
2204 <dl><dt> term</dt><dd>
2211 Nested definition lists using html syntax
2228 Definition Lists: No nesting: Multiple dd's
2242 Definition Lists: Indentation: Regular
2258 Definition Lists: Indentation: Missing 1st level
2272 Definition Lists: Indentation: Multi-level indent
2276 <dl><dd><dl><dd><dl><dd>i3
2284 Definition Lists: Hacky use to indent tables
2291 should be left alone
2293 <dl><dd><dl><dd><table>
2298 </td></tr></table></dd></dl></dd></dl>
2300 should be left alone
2303 ## The PHP parser treats : items (dd) without a corresponding ; item (dt)
2304 ## as an empty dt item. It also ignores all but the last ";" when followed
2305 ## by ":" later on. So, ";" are not ignored in ";;;t3" but are ignored in
2306 ## ";;;t3 :d1". So, PHP parser behavior is a little inconsistent wrt multiple
2309 ## Ex: ";;t2 ::d2" is transformed into:
2321 ## But, Parsoid treats "; :" as a tight atomic unit and excess ":" as plain text
2322 ## So, the same wikitext above (;;t2 ::d2) is transformed into:
2333 ## All Parsoid only definition list tests have this difference.
2335 ## See also: https://bugzilla.wikimedia.org/show_bug.cgi?id=6569
2336 ## and http://lists.wikimedia.org/pipermail/wikitext-l/2011-November/000483.html
2339 Table / list interaction: indented table with lists in table contents
2361 </td></tr></table></dd></dl>
2366 Table / list interaction: lists nested in tables nested in indented lists
2391 </td></tr></table></dd></dl>
2399 Definition Lists: Nesting: Multi-level (Parsoid only)
2429 Definition Lists: Nesting: Test 2 (Parsoid only)
2449 Definition Lists: Nesting: Test 3 (Parsoid only)
2477 Definition Lists: Nesting: Test 4
2482 <dl><dd><dl><dd><dl><dt>t3
2491 ## The Parsoid team believes the following three test exposes a
2492 ## bug in the PHP parser. (Parsoid team thinks the PHP parser is
2493 ## wrong to close the <dl> after the <dt> containing the <ul>.)
2495 Definition Lists: Mixed Lists: Test 1 (php)
2503 <dl><dd><dl><dt><ul><li> foo
2513 Definition Lists: Mixed Lists: Test 1 (parsoid)
2521 <dl><dd><dl><dt><ul><li> foo
2522 </li></ul></dt><dd><ul><li> bar
2523 </li></ul></dd><dt> baz</dt></dl></dd></dl>
2527 Definition Lists: Mixed Lists: Test 2
2541 Definition Lists: Mixed Lists: Test 3
2546 <ul><li><dl><dd><dl><dd><dl><dd> d1
2557 Definition Lists: Mixed Lists: Test 4
2562 <ul><li><dl><dt>d1 </dt><dd>d2
2563 </dd><dt>d3 </dt><dd>d4
2571 Definition Lists: Mixed Lists: Test 5
2586 Definition Lists: Mixed Lists: Test 6
2591 <ol><li><ul><li><dl><dd>d1
2603 Definition Lists: Mixed Lists: Test 7
2617 Definition Lists: Mixed Lists: Test 8
2633 Definition Lists: Mixed Lists: Test 9
2637 <ul><li><dl><dt>foo </dt><dd>bar
2645 Definition Lists: Mixed Lists: Test 10
2649 <ul><li><ol><li><dl><dt>foo </dt><dd>bar
2656 # The Parsoid team disagrees with the PHP parser's seemingly-random
2657 # rules regarding dd/dt on the next two tests. Parsoid is more
2658 # consistent, and recognizes the shared nesting and keeps the
2659 # still-open tags around until the nesting is complete.
2662 Definition Lists: Mixed Lists: Test 11 (php)
2669 <ul><li><ol><li><ul><li><ol><li><dl><dt>foo </dt><dd><ul><li><dl><dt><dl><dt>bar
2674 <dl><dt>boo </dt><dd>baz
2683 Definition Lists: Mixed Lists: Test 11 (parsoid)
2705 <dt>foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
2706 <dd data-parsoid='{"stx":"row"}'>bar</dd></dl></dt></dl></li></ul></dt>
2707 <dt>boo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
2708 <dd data-parsoid='{"stx":"row"}'>baz</dd></dl></li></ol></li></ul></li></ol></li></ul>
2713 Definition Lists: Weird Ones: Test 1 (php)
2717 *#;*::;; foo : bar (who uses this?)
2719 <ul><li><ol><li><dl><dt> foo </dt><dd><ul><li><dl><dd><dl><dd><dl><dt><dl><dt> bar (who uses this?)
2731 Definition Lists: Weird Ones: Test 1 (parsoid)
2735 *#;*::;; foo : bar (who uses this?)
2752 <dt> foo<span typeof="mw:Placeholder" data-parsoid='{"src":" "}'> </span></dt>
2753 <dd data-parsoid='{"stx":"row"}'> bar (who uses this?)</dd></dl></dt></dl></dd></dl></dd></dl></li></ul></dt></dl></li></ol></li></ul>
2760 External links: non-bracketed
2762 Non-bracketed: http://example.com
2764 <p>Non-bracketed: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
2769 External links: numbered
2771 Numbered: [http://example.com]
2772 Numbered: [http://example.net]
2773 Numbered: [http://example.com]
2775 <p>Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[1]</a>
2776 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.net">[2]</a>
2777 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[3]</a>
2782 External links: specified text
2784 Specified text: [http://example.com link]
2786 <p>Specified text: <a rel="nofollow" class="external text" href="http://example.com">link</a>
2791 External links: trail
2793 Linktrails should not work for external links: [http://example.com link]s
2795 <p>Linktrails should not work for external links: <a rel="nofollow" class="external text" href="http://example.com">link</a>s
2800 External links: dollar sign in URL
2802 http://example.com/1$2345
2804 <p><a rel="nofollow" class="external free" href="http://example.com/1$2345">http://example.com/1$2345</a>
2809 External links: dollar sign in URL (named)
2811 [http://example.com/1$2345]
2813 <p><a rel="nofollow" class="external autonumber" href="http://example.com/1$2345">[1]</a>
2818 External links: open square bracket forbidden in URL (bug 4377)
2820 http://example.com/1[2345
2822 <p><a rel="nofollow" class="external free" href="http://example.com/1">http://example.com/1</a>[2345
2827 External links: open square bracket forbidden in URL (named) (bug 4377)
2829 [http://example.com/1[2345]
2831 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
2836 External links: nowiki in URL link text (bug 6230)
2838 [http://example.com/ <nowiki>''example site''</nowiki>]
2840 <p><a rel="nofollow" class="external text" href="http://example.com/">''example site''</a>
2845 External links: newline forbidden in text (bug 6230 regression check)
2847 [http://example.com/ first
2850 <p>[<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> first
2856 External links: Pipe char between url and text
2858 [http://example.com | link]
2860 <p><a rel="nofollow" class="external text" href="http://example.com">| link</a>
2865 External links: protocol-relative URL in brackets
2867 [//example.com/ Test]
2869 <p><a rel="nofollow" class="external text" href="//example.com/">Test</a>
2874 External links: protocol-relative URL in brackets without text
2878 <p><a rel="nofollow" class="external autonumber" href="//example.com">[1]</a>
2883 External links: protocol-relative URL in free text is left alone
2887 <p>//example.com/Foo
2892 External links: protocol-relative URL in the middle of a word is left alone (bug 30269)
2894 foo//example.com/Foo
2896 <p>foo//example.com/Foo
2903 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2905 <p>External image: <img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
2910 External image from https
2912 External image from https: https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2914 <p>External image from https: <img src="https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
2919 External image (when not allowed)
2921 wgAllowExternalImages=0
2923 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2925 <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>
2930 Link to non-http image, no img tag
2932 Link to non-http image, no img tag: ftp://example.com/test.jpg
2934 <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>
2939 External links: terminating separator
2941 Terminating separator: http://example.com/thing,
2943 <p>Terminating separator: <a rel="nofollow" class="external free" href="http://example.com/thing">http://example.com/thing</a>,
2948 External links: intervening separator
2950 Intervening separator: http://example.com/1,2,3
2952 <p>Intervening separator: <a rel="nofollow" class="external free" href="http://example.com/1,2,3">http://example.com/1,2,3</a>
2957 External links: old bug with URL in query
2959 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
2961 <p>Old bug with URL in query: <a rel="nofollow" class="external text" href="http://example.com/thing?url=http://example.com">link</a>
2966 External links: old URL-in-URL bug, mixed protocols
2968 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
2970 <p>And again with mixed protocols: <a rel="nofollow" class="external text" href="ftp://example.com?url=http://example.com">link</a>
2975 External links: URL in text
2977 URL in text: [http://example.com http://example.com]
2979 <p>URL in text: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
2984 External links: Clickable images
2986 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
2988 <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>
2993 External links: raw ampersand
2995 Old & use: http://x&y
2997 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
3002 External links: encoded ampersand
3004 Old & use: http://x&y
3006 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
3011 External links: encoded equals (bug 6102)
3013 http://example.com/?foo=bar
3015 <p><a rel="nofollow" class="external free" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a>
3020 External links: [raw ampersand]
3022 Old & use: [http://x&y]
3024 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3029 External links: [encoded ampersand]
3031 Old & use: [http://x&y]
3033 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
3038 External links: [encoded equals] (bug 6102)
3040 [http://example.com/?foo=bar]
3042 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
3047 External links: [IDN ignored character reference in hostname; strip it right off]
3049 [http://e‌xample.com/]
3051 <p><a rel="nofollow" class="external autonumber" href="http://example.com/">[1]</a>
3055 # FIXME: This test (the IDN characters in the text of a link) is an inconsistency.
3056 # Where an external link could easily circumvent the sanitization of the text of
3057 # a link like this (where an IDN-ignore character is in the URL somewhere), this
3058 # test demands a higher standard. That's a bit strange.
3062 # http://example.com -> [http://example.com|http://example.com]
3063 # [http://example.com|http://example.com] -> [http://example.com|http://example.com]
3065 # The first example is sanitized, but the second is not. Any security benefits
3066 # from this production are trivial to circumvent. Either remove this test and
3067 # let the parser(s) do their thing unaccosted, or fix the inconsistency and change
3068 # the test accordingly.
3073 External links: IDN ignored character reference in hostname; strip it right off
3075 http://e‌xample.com/
3077 <p><a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>
3082 External links: www.jpeg.org (bug 554)
3086 <p><a rel="nofollow" class="external free" href="http://www.jpeg.org">http://www.jpeg.org</a>
3091 External links: URL within URL (original bug 2)
3093 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
3095 <p><a rel="nofollow" class="external autonumber" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp">[1]</a>
3100 BUG 361: URL inside bracketed URL
3102 [http://www.example.com/foo http://www.example.com/bar]
3104 <p><a rel="nofollow" class="external text" href="http://www.example.com/foo">http://www.example.com/bar</a>
3109 BUG 361: URL within URL, not bracketed
3111 http://www.example.com/foo?=http://www.example.com/bar
3113 <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>
3118 BUG 289: ">"-token in URL-tail
3120 http://www.example.com/<hello>
3122 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><hello>
3127 BUG 289: literal ">"-token in URL-tail
3129 http://www.example.com/<b>html</b>
3131 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><b>html</b>
3136 BUG 289: ">"-token in bracketed URL
3138 [http://www.example.com/<hello> stuff]
3140 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><hello> stuff</a>
3145 BUG 289: literal ">"-token in bracketed URL
3147 [http://www.example.com/<b>html</b> stuff]
3149 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><b>html</b> stuff</a>
3154 BUG 289: literal double quote at end of URL
3156 http://www.example.com/"hello"
3158 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a>"hello"
3163 BUG 289: literal double quote in bracketed URL
3165 [http://www.example.com/"hello" stuff]
3167 <p><a rel="nofollow" class="external text" href="http://www.example.com/">"hello" stuff</a>
3172 External links: multiple legal whitespace is fine, Magnus. Don't break it please. (bug 5081)
3174 [http://www.example.com test]
3176 <p><a rel="nofollow" class="external text" href="http://www.example.com">test</a>
3181 External links: link text with spaces
3183 [http://www.example.com a b c]
3184 [http://www.example.com ''a'' ''b'']
3186 <p><a rel="nofollow" class="external text" href="http://www.example.com">a b c</a>
3187 <a rel="nofollow" class="external text" href="http://www.example.com"><i>a</i> <i>b</i></a>
3192 External links: wiki links within external link (Bug 3695)
3194 [http://example.com [[wikilink]] embedded in ext link]
3196 <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>
3201 BUG 787: Links with one slash after the url protocol are invalid
3205 [http:/example.com title]
3207 <p>http:/example.com
3208 </p><p>[http:/example.com title]
3213 Bracketed external links with template-generated invalid target
3215 [{{echo|http:/example.com}} title]
3217 <p>[http:/example.com title]
3222 Bug 2702: Mismatched <i>, <b> and <a> tags are invalid
3224 ''[http://example.com text'']
3225 [http://example.com '''text]'''
3226 ''Something [http://example.com in italic'']
3227 ''Something [http://example.com mixed''''', even bold]'''
3228 '''''Now [http://example.com both''''']
3230 <p><a rel="nofollow" class="external text" href="http://example.com"><i>text</i></a>
3231 <a rel="nofollow" class="external text" href="http://example.com"><b>text</b></a>
3232 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>in italic</i></a>
3233 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>mixed</i><b>, even bold</b></a>
3234 <i><b>Now </b></i><a rel="nofollow" class="external text" href="http://example.com"><i><b>both</b></i></a>
3240 Bug 4781: %26 in URL
3242 http://www.example.com/?title=AT%26T
3244 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a>
3248 # According to http://dev.w3.org/html5/spec/Overview.html#parsing-urls a plain
3249 # % is actually legal in HTML5. Any change in output would need testing though.
3251 Bug 4781, 5267: %25 in URL
3253 http://www.example.com/?title=100%25_Bran
3255 <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>
3260 Bug 4781, 5267: %28, %29 in URL
3262 http://www.example.com/?title=Ben-Hur_%281959_film%29
3264 <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>
3270 Bug 4781: %26 in autonumber URL
3272 [http://www.example.com/?title=AT%26T]
3274 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=AT%26T">[1]</a>
3279 Bug 4781, 5267: %26 in autonumber URL
3281 [http://www.example.com/?title=100%25_Bran]
3283 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=100%25_Bran">[1]</a>
3288 Bug 4781, 5267: %28, %29 in autonumber URL
3290 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
3292 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">[1]</a>
3298 Bug 4781: %26 in bracketed URL
3300 [http://www.example.com/?title=AT%26T link]
3302 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=AT%26T">link</a>
3307 Bug 4781, 5267: %26 in bracketed URL
3309 [http://www.example.com/?title=100%25_Bran link]
3311 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=100%25_Bran">link</a>
3316 Bug 4781, 5267: %28, %29 in bracketed URL
3318 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
3320 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a>
3325 External link containing double-single-quotes in text '' (bug 4598 sanity check)
3327 Some [http://example.com/ pretty ''italics'' and stuff]!
3329 <p>Some <a rel="nofollow" class="external text" href="http://example.com/">pretty <i>italics</i> and stuff</a>!
3334 External link containing double-single-quotes in text embedded in italics (bug 4598 sanity check)
3336 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
3338 <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>
3343 External link containing double-single-quotes with no space separating the url from text in italics
3345 [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]].]
3347 <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>
3352 External link with comments in link text
3354 [http://www.google.com Google <!-- comment -->]
3356 <p><a rel="nofollow" class="external text" href="http://www.google.com">Google </a>
3361 URL-encoding in URL functions (single parameter)
3363 {{localurl:Some page|amp=&}}
3365 <p>/index.php?title=Some_page&amp=&
3370 URL-encoding in URL functions (multiple parameters)
3372 {{localurl:Some page|q=?&=&}}
3374 <p>/index.php?title=Some_page&q=?&amp=&
3381 http://example.com/index.php?foozoid%5B%5D=bar
3383 http://example.com/index.php?foozoid[]=bar
3385 <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>
3386 </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>
3391 IPv6 urls (bug 21261)
3395 http://[2404:130:0:1000::187:2]/index.php
3397 <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>
3402 Non-extlinks in brackets
3411 [{{echo|foo}} ''bar'']
3412 [{{echo|foo}}l's] errand
3413 [{{echo|foo}}l's errand]
3415 [url=http://example.com]
3428 [url=<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>]
3433 Parsoid: Percent encoding in external links
3437 [https://github.com/search?l=&q=ResourceLoader+%40wikimedia Search]
3439 <p><a rel="mw:ExtLink"
3440 href="https://github.com/search?l=&q=ResourceLoader+%40wikimedia">Search</a></p>
3444 Parsoid: use url link syntax for links where the content is equal the link
3451 <p><a rel="mw:ExtLink" href="http://example.com">http://example.com</a></p>
3461 Normal text. '''Bold text.''' Normal text. ''Italic text.''
3463 Normal text. '''''Bold italic text.''''' Normal text.
3465 <p>Normal text. <b>Bold text.</b> Normal text. <i>Italic text.</i>
3466 </p><p>Normal text. <i><b>Bold italic text.</b></i> Normal text.
3472 Unclosed and unmatched quotes (php)
3476 '''''Bold italic text '''with bold deactivated''' in between.'''''
3478 '''''Bold italic text ''with italic deactivated'' in between.'''''
3482 ..spanning two paragraphs (should not work).'''
3484 '''Bold tag left open
3486 ''Italic tag left open
3490 <!-- Unmatching number of opening, closing tags: -->
3491 '''This year''''s election ''should'' beat '''last year''''s.
3493 ''Tom'''s car is bigger than ''Susan'''s.
3495 Plain ''italic'''s plain
3497 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
3498 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
3499 </p><p><b>Bold text..</b>
3500 </p><p>..spanning two paragraphs (should not work).
3501 </p><p><b>Bold tag left open</b>
3502 </p><p><i>Italic tag left open</i>
3504 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
3505 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
3506 </p><p>Plain <i>italic'</i>s plain
3509 # Parsoid inserts an empty bold tag pair at the end of the line, that the PHP
3510 # parser strips. The wikitext contains just the first half of the bold
3511 # quote pair. (There's also a case where Parsoid nests <b> and <i>
3512 # differently than the PHP parser.)
3514 Unclosed and unmatched quotes (parsoid)
3518 '''''Bold italic text '''with bold deactivated''' in between.'''''
3520 '''''Bold italic text ''with italic deactivated'' in between.'''''
3524 ..spanning two paragraphs (should not work).'''
3526 '''Bold tag left open
3528 ''Italic tag left open
3532 <!-- Unmatching number of opening, closing tags: -->
3533 '''This year''''s election ''should'' beat '''last year''''s.
3535 ''Tom'''s car is bigger than ''Susan'''s.
3537 Plain ''italic'''s plain
3539 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
3540 </p><p><i><b>Bold italic text </b></i><b>with italic deactivated<i> in between.</i></b>
3541 </p><p><b>Bold text..</b>
3542 </p><p>..spanning two paragraphs (should not work).<b></b>
3543 </p><p><b>Bold tag left open</b>
3544 </p><p><i>Italic tag left open</i>
3546 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
3547 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
3548 </p><p>Plain <i>italic'</i>s plain
3555 ### some content taken from http://meta.wikimedia.org/wiki/MediaWiki_User%27s_Guide:_Using_tables
3558 # This should not produce <table></table> as <table><tr><td></td></tr></table>
3559 # is the bare minimum required by the spec, see:
3560 # http://www.w3.org/TR/xhtml-modularization/dtd_module_defs.html#a_module_Basic_Tables
3562 A table with no data. (php)
3569 # Parsoid team replies: empty table tags are legal in HTML5
3571 A table with no data. (parsoid)
3580 # A table with nothing but a caption is invalid XHTML, we might want to render
3581 # this as <p>caption</p>
3583 A table with nothing but a caption (php)
3593 </caption><tr><td></td></tr></table>
3596 # Parsoid team replies: table with only a caption is legal in HTML5
3598 A table with nothing but a caption (parsoid)
3606 <table><caption> caption</caption></table>
3610 A table with caption with default-spaced attributes and a table row
3613 |+ style="color: red;" | caption1
3619 <caption style="color: red;"> caption1
3628 A table with captions with non-default spaced attributes and a table row
3631 |+style="color: red;"|caption2
3632 |+ style="color: red;"| caption3
3638 <caption style="color: red;">caption2
3640 <caption style="color: red;"> caption3
3649 Table td-cell syntax variations
3653 | foo bar foo || baz
3654 | style='color:red;' | baz
3655 | style='color:red;' || baz
3662 <td> foo bar foo </td>
3665 <td style="color:red;"> baz
3667 <td> style='color:red;' </td>
3695 Simple table but with multiple dashes for row wikitext
3713 Multiplication table
3715 {| border="1" cellpadding="2"
3716 |+Multiplication table
3718 ! × !! 1 !! 2 !! 3
3736 <table border="1" cellpadding="2">
3737 <caption>Multiplication table
3784 Accept "||" in table headings
3799 Accept "||" in indented table headings
3809 </th></tr></table></dd></dl>
3814 Accept empty attributes in td/th cells (td/th cells starting with leading ||)
3831 Accept "| !" at start of line in tables (ignore !-attribute)
3835 | !style="color:red" | bar
3847 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 +/-
3851 |style='color:red;'|+1
3852 |style='color:blue;'|-1
3864 <td style="color:red;">+1
3866 <td style="color:blue;">-1
3890 |rowspan=2| Cell 2, row 1 (and 2)
3901 <td rowspan="2"> Cell 2, row 1 (and 2)
3919 {| bgcolor=#ABCDEF border=2
3924 |the original table again
3932 <table bgcolor="#ABCDEF" border="2">
3940 <td>the original table again
3946 Invalid attributes in table cell (bug 1830)
3961 Table security: embedded pipes (http://lists.wikimedia.org/mailman/htdig/wikitech-l/2006-April/022293.html)
3964 | |[ftp://|x||]" onmouseover="alert(document.cookie)">test
3968 <td>[<a rel="nofollow" class="external free" href="ftp://%7Cx">ftp://%7Cx</a></td>
3969 <td>]" onmouseover="alert(document.cookie)">test
3978 Indented table markup mixed with indented pre content (proposed in bug 6200)
3983 Text that should be rendered preformatted
3991 <pre>Text that should be rendered preformatted
4000 Template-generated table cell attributes and cell content
4008 <td style="color: red"> Foo
4014 Template-generated table cell attributes and cell content (2)
4017 |align=center {{table_attribs}}
4022 <td align="center" style="color: red"> Foo
4028 Template-generated table cell attributes and cell content (3)
4031 |align=center {{table_cells}}
4036 <td align="center" style="color: red"> Foo </td>
4044 Table with row followed by newlines and table heading
4062 Table with empty line following the start tag
4079 # FIXME: Preserve the attribute properly (with an empty string as value) in
4080 # the PHP parser. Parsoid implements the behavior below.
4082 Table attributes with empty value
4094 </td></tr></tbody></table>
4099 Wikitext table with a lot of comments
4122 Wikitext table with double-line table cell
4139 Table cell with a single comment
4155 # The expected HTML structure in this test is debatable. The PHP parser does
4156 # not parse this kind of table at all. The main focus for Parsoid is on
4157 # round-tripping, so this output is ok for now. TODO: revisit!
4159 Wikitext table with html-syntax row (Parsoid)
4171 <td>foo</td></tr></tbody></table>
4175 Implicit <td> after a |-
4176 (PHP parser relies on Tidy to add the missing <td> tags)
4178 parsoid=wt2html,wt2wt
4191 Pres should be recognized in an explicit <td> context, but not in an implicit <td> context
4192 (PHP parser relies on Tidy to add the missing <td> tags)
4194 parsoid=wt2html,wt2wt
4206 <tr><td><pre>a</pre></td></tr>
4207 <tr><td> b</td></tr>
4213 Lists should be recognized in an implicit <td> context
4214 (PHP parser relies on Tidy to add the missing <td> tags)
4216 parsoid=wt2html,wt2wt
4225 <td><ul><li>a</li></ul></td>
4234 Plain link, capitalized
4238 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
4243 Plain link, uncapitalized
4247 <p><a href="/wiki/Main_Page" title="Main Page">main Page</a>
4254 [[Main Page|The Main Page]]
4256 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
4261 Piped link with comment in link text
4263 [[Main Page|The Main<!--front--> Page]]
4265 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
4274 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig</a>
4279 Broken link with fragment
4281 [[Zigzagzogzagzig#zug]]
4283 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig#zug</a>
4288 Special page link with fragment
4290 [[Special:Version#anchor]]
4292 <p><a href="/wiki/Special:Version#anchor" title="Special:Version">Special:Version#anchor</a>
4297 Nonexistent special page link with fragment
4299 [[Special:ThisNameWillHopefullyNeverBeUsed#anchor]]
4301 <p><a href="/wiki/Special:ThisNameWillHopefullyNeverBeUsed" class="new" title="Special:ThisNameWillHopefullyNeverBeUsed (page does not exist)">Special:ThisNameWillHopefullyNeverBeUsed#anchor</a>
4308 xxx[[main Page]], xxx[[Main Page]], Xxx[[main Page]] XXX[[main Page]], XXX[[Main Page]]
4310 <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>
4317 [[Main Page]]xxx, [[Main Page]]XXX, [[Main Page]]!!!
4319 <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>!!!
4330 Bug 43661: Piped links with identical prefixes
4332 [[prefixed article|prefixed articles with spaces]]
4334 [[prefixed article|prefixed articlesaoeu]]
4336 [[Main Page|Main Page test]]
4338 <p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articles with spaces</a>
4339 </p><p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articlesaoeu</a>
4340 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page test</a>
4346 Link with HTML entity in suffix / tail
4348 [[Main Page]]", [[Main Page]]a
4350 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>", <a href="/wiki/Main_Page" title="Main Page">Main Page</a>a
4355 Link with 3 brackets
4364 Piped link with 3 brackets
4366 [[[main page|the main page]]]
4368 <p>[[[main page|the main page]]]
4373 Link with multiple pipes
4375 [[Main Page|The|Main|Page]]
4377 <p><a href="/wiki/Main_Page" title="Main Page">The|Main|Page</a>
4384 [[Talk:Parser testing]], [[Meta:Disclaimers]]
4386 <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>
4391 Piped link to namespace
4393 [[Meta:Disclaimers|The disclaimers]]
4395 <p><a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">The disclaimers</a>
4402 [[Usually caused by a typo (oops}]]
4404 <p>[[Usually caused by a typo (oops}]]
4409 Link containing % (not as a hex sequence)
4413 <p><a href="/index.php?title=7%25_Solution&action=edit&redlink=1" class="new" title="7% Solution (page does not exist)">7% Solution</a>
4418 Link containing % as a single hex sequence interpreted to char
4422 <p><a href="/index.php?title=7%25_Solution&action=edit&redlink=1" class="new" title="7% Solution (page does not exist)">7% Solution</a>
4427 Link containing % as a double hex sequence interpreted to hex sequence
4431 <p>[[7%2525 Solution]]
4436 Link containing "#<" and "#>" % as a hex sequences- these are valid section anchors
4437 Example for such a section: == < ==
4439 [[%23%3c]][[%23%3e]]
4441 <p><a href="#.3C">#<</a><a href="#.3E">#></a>
4446 Link containing "<#" and ">#" as a hex sequences
4448 [[%3c%23]][[%3e%23]]
4450 <p>[[%3c%23]][[%3e%23]]
4455 Link containing an equals sign
4457 [[Special:BookSources/isbn=4-00-026157-6]]
4459 <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>
4466 Just a test of an article title containing a tilde.
4469 # note that links containing signatures, like [[Foo~~~~]], are
4470 # massaged by the pre-save transform (PST) and so the tildes are never
4471 # seen by the parser.
4473 Link containing a tilde
4477 <p><a href="/wiki/Foo%7Ebar" title="Foo~bar">Foo~bar</a>
4482 Link containing double-single-quotes '' (bug 4598)
4484 [[Lista d''e paise d''o munno]]
4486 <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>
4491 Link containing double-single-quotes '' in text (bug 4598 sanity check)
4493 Some [[Link|pretty ''italics'' and stuff]]!
4495 <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>!
4500 Link containing double-single-quotes '' in text embedded in italics (bug 4598 sanity check)
4502 ''Some [[Link|pretty ''italics'' and stuff]]!
4504 <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>
4509 Link with double quotes in title part (literal) and alternate part (interpreted)
4511 [[File:Denys Savchenko ''Pentecoste''.jpg]]
4515 [[''Pentecoste''|Pentecoste]]
4517 [[''Pentecoste''|''Pentecoste'']]
4519 <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>
4520 </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>
4521 </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>
4522 </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>
4527 Broken image links with HTML captions (bug 39700)
4529 [[File:Nonexistent|<script></script>]]
4530 [[File:Nonexistent|100px|<script></script>]]
4531 [[File:Nonexistent|<]]
4532 [[File:Nonexistent|a<i>b</i>c]]
4534 <p><a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
4535 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
4536 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><</a>
4537 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent">abc</a>
4544 [[http://www.example.com]]
4546 <p>[<a rel="nofollow" class="external autonumber" href="http://www.example.com">[1]</a>]
4551 Plain link to URL with link text
4553 [[http://www.example.com Link text]]
4555 <p>[<a rel="nofollow" class="external text" href="http://www.example.com">Link text</a>]
4560 Plain link to protocol-relative URL
4562 [[//www.example.com]]
4564 <p>[<a rel="nofollow" class="external autonumber" href="//www.example.com">[1]</a>]
4569 Plain link to protocol-relative URL with link text
4571 [[//www.example.com Link text]]
4573 <p>[<a rel="nofollow" class="external text" href="//www.example.com">Link text</a>]
4578 Plain link to page with question mark in title
4584 <p><a href="/wiki/A%3Fb" title="A?b">A?b</a>
4585 </p><p><a href="/wiki/A%3Fb" title="A?b">Baz</a>
4590 # I'm fairly sure the expected result here is wrong.
4591 # We want these to be URL links, not pseudo-pages with URLs for titles....
4592 # However the current output is also pretty screwy.
4595 # I'm changing it to match the current output--it arguably makes more
4596 # sense in the light of the test above. Old expected result was:
4597 #<p>Piped link to URL: <a href="/index.php?title=Http://www.example.com&action=edit" class="new">an example URL</a>
4599 # But I think this test is bordering on "garbage in, garbage out" anyway.
4604 Piped link to URL: [[http://www.example.com|an example URL]]
4606 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
4611 BUG 2: [[page|http://url/]] should link to page, not http://url/
4613 [[Main Page|http://url/]]
4615 <p><a href="/wiki/Main_Page" title="Main Page">http://url/</a>
4620 BUG 337: Escaped self-links should be bold
4624 [[Bug462]] [[Bug462]]
4626 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong>
4631 Self-link to section should not be bold
4635 [[Main Page#section]]
4637 <p><a href="/wiki/Main_Page#section" title="Main Page">Main Page#section</a>
4648 Self-link to numeric title
4654 <p><strong class="selflink">0</strong>
4659 Link to numeric-equivalent title
4665 <p><a href="/wiki/00" title="00">00</a>
4670 <nowiki> inside a link
4672 [[Main<nowiki> Page</nowiki>]] [[Main Page|the main page <nowiki>[it's not very good]</nowiki>]]
4674 <p>[[Main Page]] <a href="/wiki/Main_Page" title="Main Page">the main page [it's not very good]</a>
4679 Non-breaking spaces in title
4681 [[ Main Page ]]
4683 <p><a href="/wiki/Main_Page" title="Main Page">  Main   Page  </a>
4688 Internal link with ca linktrail, surrounded by bold apostrophes (bug 27473 primary issue)
4694 <p><b><a href="/wiki/Main_Page" title="Main Page">Main Page</a></b>
4699 Internal link with ca linktrail, surrounded by italic apostrophes (bug 27473 primary issue)
4705 <p><i><a href="/wiki/Main_Page" title="Main Page">Main Page</a></i>
4710 Internal link with en linktrail: no apostrophes (bug 27473)
4716 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (page does not exist)">Something</a>'nice
4721 Internal link with ca linktrail with apostrophes (bug 27473)
4727 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (encara no existeix)">Something'nice</a>
4732 Internal link with kaa linktrail with apostrophes (bug 27473)
4738 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (bet ele jaratılmag'an)">Something'nice</a>
4749 Internal link with is link prefix
4753 Aðrir mótmælenda[[söfnuður|söfnuðir]] og
4755 <p>Aðrir <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a> og
4766 Internal link with is link trail and link prefix
4770 [[mótmælendatrú|xxx]]ar
4772 mótmælenda[[söfnuður]]
4773 mótmælenda[[söfnuður|söfnuðir]]
4774 mótmælenda[[söfnuður|söfnuðir]]xxx
4776 <p><a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">xxxar</a>
4777 <a href="/wiki/M%C3%B3tm%C3%A6lendatr%C3%BA" title="Mótmælendatrú">mótmælendatrúar</a>
4778 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuður</a>
4779 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðir</a>
4780 <a href="/wiki/S%C3%B6fnu%C3%B0ur" title="Söfnuður">mótmælendasöfnuðirxxx</a>
4785 Parsoid link trail escaping
4787 parsoid=html2wt,html2html
4791 <p><a rel="mw:WikiLink" href="Apple">apple</a>s</p>
4795 Parsoid link prefix escaping
4798 parsoid=html2wt,html2html
4800 Aðrir mótmælenda<nowiki/>[[söfnuður]]
4802 <p>Aðrir mótmælenda<a rel="mw:WikiLink" href="Söfnuður">söfnuður</a></p>
4806 Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
4814 [http://wp.org ''foo'']
4816 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> bar</a>
4817 </p><p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> <i>bar</i></a>
4818 </p><p><a rel="nofollow" class="external text" href="http://wp.org">foo</a>
4819 </p><p><a rel="nofollow" class="external text" href="http://wp.org"><i>foo</i></a>
4824 ### Interwiki links (see maintenance/interwiki.sql)
4828 Inline interwiki link
4830 [[MeatBall:SoftSecurity]]
4832 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a>
4837 Inline interwiki link with empty title (bug 2372)
4841 <p><a href="http://www.usemod.com/cgi-bin/mb.pl" class="extiw" title="meatball:">MeatBall:</a>
4846 Interwiki link encoding conversion (bug 1636)
4848 *[[Wikipedia:ro:Olteniţa]]
4849 *[[Wikipedia:ro:Olteniţa]]
4851 <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>
4852 </li><li><a href="http://en.wikipedia.org/wiki/ro:Olteni%C5%A3a" class="extiw" title="wikipedia:ro:Olteniţa">Wikipedia:ro:Olteniţa</a>
4858 Interwiki link with fragment (bug 2130)
4860 [[MeatBall:SoftSecurity#foo]]
4862 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity#foo" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity#foo</a>
4877 Double interlanguage link
4888 Interlanguage link, with prefix links
4900 Double interlanguage link, with prefix links (bug 8897)
4913 Parsoid-specific test: Wikilinks with should RT properly
4919 <p><a href="/index.php?title=WW_II&action=edit&redlink=1" class="new" title="WW II (lonkásá ezalí tɛ̂)">WW II</a>
4924 Parsoid: handle constructor well
4932 <p data-parsoid="{"dsr":[0,15,0,0]}"><a rel="mw:WikiLink" href="./Constructor" data-parsoid="{"stx":"simple","a":{"href":"./Constructor"},"sa":{"href":"constructor"},"dsr":[0,15,2,2]}">constructor</a></p>
4935 <p data-parsoid="{"dsr":[17,36,0,0]}"><a rel="mw:WikiLink" href="./Foo" data-parsoid="{"stx":"simple","a":{"href":"./Foo"},"sa":{"href":"constructor:foo"},"dsr":[17,36,2,2]}">constructor:foo</a></p>
4939 ## Redirects, Parsoid-only
4942 Simple redirect to page
4946 #REDIRECT [[Main Page]]
4948 <link rel="mw:PageProp/redirect" href="./Main_Page">
4952 Optional colon in #REDIRECT
4954 # the colon is archaic syntax. we support it for wt2html, but we
4955 # don't care that it roundtrips back to the modern syntax.
4956 parsoid=wt2html,html2html
4958 #REDIRECT:[[Main Page]]
4960 <link rel="mw:PageProp/redirect" href="./Main_Page">
4964 Whitespace in #REDIRECT with optional colon
4966 # the colon and gratuitous whitespace is archaic syntax. we support
4967 # it for wt2html, but we don't care that it roundtrips back to the
4968 # modern syntax (without extra whitespace)
4969 parsoid=wt2html,html2html
4976 <link rel="mw:PageProp/redirect" href="./Main_Page">
4980 Piped link in #REDIRECT
4982 # content after piped link is ignored. we support this syntax,
4983 # but don't care that the piped link is lost when we roundtrip this.
4986 #REDIRECT [[Main Page|bar]]
4988 <link rel="mw:PageProp/redirect" href="./Main_Page">
4992 Redirect to category
4996 #REDIRECT [[Category:Foo]]
4998 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:WikiLink/Category" href="./Category:Foo">
5002 Redirect to category with URL encoding
5006 #REDIRECT [[Category%3AFoo]]
5008 <link rel="mw:PageProp/redirect" href="./Category:Foo"><link rel="mw:WikiLink/Category" href="./Category:Foo">
5012 Redirect to category page
5014 parsoid=wt2html,html2html
5016 #REDIRECT [[:Category:Foo]]
5018 <p><a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a></p>
5022 Redirect to image page (1)
5026 #REDIRECT [[File:Wiki.png]]
5028 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
5032 Redirect to image page (2)
5036 #REDIRECT [[Image:Wiki.png]]
5038 <link rel="mw:PageProp/redirect" href="./File:Wiki.png">
5042 Redirect to language
5046 #REDIRECT [[en:File:Wiki.png]]
5048 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
5052 Redirect to interwiki
5056 #REDIRECT [[meatball:File:Wiki.png]]
5058 <link rel="mw:PageProp/redirect" href="File:Wiki.png">
5062 Non-English #REDIRECT
5067 #TILVÍSUN [[Main Page]]
5069 <link rel="mw:PageProp/redirect" href="./Main_Page">
5086 Broken br tag sanitization
5096 # TODO: Fix html2html mode (bug 51055)!
5098 Parsoid: Broken br tag recognition
5108 Incorrecly removing closing slashes from correctly formed XHTML
5110 <br style="clear:both;" />
5112 <p><br style="clear:both;" />
5117 Failing to transform badly formed HTML into correct XHTML
5119 <br style="clear: left;">
5120 <br style="clear: right;">
5121 <br style="clear: both;">
5123 <p><br style="clear: left;" />
5124 <br style="clear: right;" />
5125 <br style="clear: both;" />
5130 Handling html with a div self-closing tag
5139 <p><div title />
5143 <p><div title=bar />
5144 <div title=bar/>
5146 <div title="bar/"></div>
5152 Handling html with a br self-closing tag
5161 <p><br title="title" />
5162 <br title="title" />
5171 Horizontal ruler (should it add that extra space?)
5185 Horizontal ruler -- 4+ dashes render hr
5194 Horizontal ruler -- eats additional dashes on the same line
5203 Horizontal ruler -- does not collapse dashes on consecutive lines
5214 Horizontal ruler -- <4 dashes render as plain text
5223 Horizontal ruler -- Supports content following dashes on same line
5232 ### Block-level elements
5255 <ol><li>Numbered list
5272 ***#Number on level 4
5274 **#Number on level 3
5275 **#Number on level 3
5279 #** Level 3, but ordered
5282 <ol><li> with numbers
5284 <ul><li> and bullets
5286 <ol><li> and numbers
5288 </li><li>bullets again
5289 <ul><li>bullet level 2
5290 <ul><li>bullet level 3
5291 <ol><li>Number on level 4
5294 </li><li>bullet level 2
5295 <ol><li>Number on level 3
5296 </li><li>Number on level 3
5299 <ol><li>number level 2
5302 <ul><li><ul><li> Level 3
5306 <ol><li><ul><li><ul><li> Level 3, but ordered
5340 Nested lists 3 (first element empty)
5353 Nested lists 4 (first element empty)
5366 Nested lists 5 (both elements empty)
5379 Nested lists 6 (both elements empty)
5392 Nested lists 7 (skip initial nesting levels)
5396 <ul><li><ul><li><ul><li> foo
5404 Nested lists 8 (multiple nesting transitions)
5412 <ul><li><ul><li> bar
5422 1. Lists with start-of-line-transparent tokens before bullets: Comments
5436 2. Lists with start-of-line-transparent tokens before bullets: Template close
5448 List items are not parsed correctly following a <pre> block (bug 785)
5454 <ul><li> <pre>foo</pre>
5455 </li><li> <pre>bar</pre>
5462 List items from template
5473 * notSOL{{inner list}}
5492 List interrupted by empty line or heading
5502 <ul><li><ul><li> bar
5505 <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>
5506 <ul><li> Another list item
5512 Multiple list tags generated by templates
5527 Single-comment whitespace lines dont break lists, and neither do multi-comment whitespace lines
5530 <!--This line will NOT split the list-->
5532 <!--This line will NOT split the list either-->
5534 <!--foo--> <!----> <!--This line NOT split the list either-->
5546 Replacing whitespace with tabs still doesn't break the list (gerrit 78327)
5549 <!--This line will NOT split the list-->
5551 <!--This line will NOT split the list either-->
5553 <!--foo--> <!----> <!--This line NOT split the list
5567 (Cannot test this with PHP parser since it relies on Tidy for the hack)
5569 parsoid=wt2html,wt2wt
5573 * {{echo|<li>templated li-hack}}
5574 * <!--foo--> <li> unsupported li-hack with preceding comments
5577 <li><li>not a li-hack
5583 <li about="#mwt1" typeof="mw:Transclusion" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<li>templated li-hack"}}}'>templated li-hack</li>
5584 <li> <!--foo--> </li><li> li-hack with preceding comments</li></ul>
5587 <li></li><li>not a li-hack
5593 Parsoid: Make sure nested lists are serialized on their own line even if HTML contains no newlines
5604 <ol><li> foo<ol><li> bar</li></ol></li></ol><ul><li> foo<ul><li> bar</li></ul></li></ul><dl><dd> foo<dl><dd> bar</dd></dl></dd></dl>
5608 Parsoid: Test of whitespace serialization with Templated bullets
5615 <li> </li><li about="#mwt1" typeof="mw:Transclusion" data-mw='{"target":{"wt":"bullet","href":"./Template:Bullet"},"params":{},"i":0}'> Bar</li>
5619 # ------------------------------------------------------------------------
5620 # The next set of tests are about Parsoid's ability to handle badly nested
5621 # tags (parse, minimize scope of fixup, and roundtrip back)
5622 # ------------------------------------------------------------------------
5625 Unbalanced closing block tags break a list
5626 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
5636 </li></ul></div><div>
5642 Unbalanced closing non-block tags don't break a list
5643 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
5653 <ul><li>a<span></span>
5659 Unclosed formatting tags that straddle lists are closed and reopened
5660 (Parsoid-only since php parser generates broken html -- relies on Tidy to fix up)
5668 </li><li> <s> b </s>
5673 List embedded in a non-block tag
5674 (Ugly Parsoid output -- worth fixing; Disabled for PHP parser since it relies on Tidy)
5682 <p><small></small></p>
5688 <p><small></small></p>
5695 # Note that the current date is hard-coded as
5696 # 1970-01-01T00:02:03Z (a Thursday)
5697 # when running parser tests. The timezone is also fixed to GMT, so
5698 # local date will be identical to current date.
5701 Magic Word: {{CURRENTDAY}}
5710 Magic Word: {{CURRENTDAY2}}
5719 Magic Word: {{CURRENTDAYNAME}}
5728 Magic Word: {{CURRENTDOW}}
5737 Magic Word: {{CURRENTMONTH}}
5746 Magic Word: {{CURRENTMONTH1}}
5755 Magic Word: {{CURRENTMONTHABBREV}}
5757 {{CURRENTMONTHABBREV}}
5764 Magic Word: {{CURRENTMONTHNAME}}
5766 {{CURRENTMONTHNAME}}
5773 Magic Word: {{CURRENTMONTHNAMEGEN}}
5775 {{CURRENTMONTHNAMEGEN}}
5782 Magic Word: {{CURRENTTIME}}
5791 Magic Word: {{CURRENTHOUR}}
5800 Magic Word: {{CURRENTWEEK}} (@bug 4594)
5809 Magic Word: {{CURRENTYEAR}}
5818 Magic Word: {{CURRENTTIMESTAMP}}
5820 {{CURRENTTIMESTAMP}}
5827 Magic Words LOCAL (UTC)
5831 * {{LOCALMONTHNAME}}
5832 * {{LOCALMONTHNAMEGEN}}
5833 * {{LOCALMONTHABBREV}}
5842 * {{LOCALTIMESTAMP}}
5857 </li><li> 19700101000203
5863 Magic Word: {{FULLPAGENAME}}
5865 title=[[User:Ævar Arnfjörð Bjarmason]]
5869 <p>User:Ævar Arnfjörð Bjarmason
5874 Magic Word: {{FULLPAGENAMEE}}
5876 title=[[User:Ævar Arnfjörð Bjarmason]]
5880 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
5885 Magic Word: {{TALKSPACE}}
5887 title=[[User:Ævar Arnfjörð Bjarmason]]
5896 Magic Word: {{TALKSPACE}}, same namespace
5898 title=[[User talk:Ævar Arnfjörð Bjarmason]]
5907 Magic Word: {{TALKSPACE}}, main namespace
5909 title=[[Parser Test]]
5918 Magic Word: {{TALKSPACEE}}
5920 title=[[User:Ævar Arnfjörð Bjarmason]]
5929 Magic Word: {{SUBJECTSPACE}}
5931 title=[[User talk:Ævar Arnfjörð Bjarmason]]
5940 Magic Word: {{SUBJECTSPACE}}, same namespace
5942 title=[[User:Ævar Arnfjörð Bjarmason]]
5951 Magic Word: {{SUBJECTSPACE}}, main namespace
5953 title=[[Parser Test]]
5961 Magic Word: {{SUBJECTSPACEE}}
5963 title=[[User talk:Ævar Arnfjörð Bjarmason]]
5972 Magic Word: {{NAMESPACE}}
5974 title=[[User:Ævar Arnfjörð Bjarmason]]
5983 Magic Word: {{NAMESPACEE}}
5985 title=[[User:Ævar Arnfjörð Bjarmason]]
5994 Magic Word: {{NAMESPACENUMBER}}
5996 title=[[User:Ævar Arnfjörð Bjarmason]]
6005 Magic Word: {{SUBPAGENAME}}
6007 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
6016 Magic Word: {{SUBPAGENAMEE}}
6018 title=[[Ævar Arnfjörð Bjarmason/sub ö]] subpage
6027 Magic Word: {{ROOTPAGENAME}}
6029 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
6033 <p>Ævar Arnfjörð Bjarmason
6038 Magic Word: {{ROOTPAGENAMEE}}
6040 title=[[Ævar Arnfjörð Bjarmason/sub/sub2]] subpage
6044 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
6049 Magic Word: {{BASEPAGENAME}}
6051 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
6055 <p>Ævar Arnfjörð Bjarmason
6060 Magic Word: {{BASEPAGENAMEE}}
6062 title=[[Ævar Arnfjörð Bjarmason/sub]] subpage
6066 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
6071 Magic Word: {{TALKPAGENAME}}
6073 title=[[User:Ævar Arnfjörð Bjarmason]]
6077 <p>User talk:Ævar Arnfjörð Bjarmason
6082 Magic Word: {{TALKPAGENAMEE}}
6084 title=[[User:Ævar Arnfjörð Bjarmason]]
6088 <p>User_talk:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
6093 Magic Word: {{SUBJECTPAGENAME}}
6095 title=[[User talk:Ævar Arnfjörð Bjarmason]]
6099 <p>User:Ævar Arnfjörð Bjarmason
6104 Magic Word: {{SUBJECTPAGENAMEE}}
6106 title=[[User talk:Ævar Arnfjörð Bjarmason]]
6108 {{SUBJECTPAGENAMEE}}
6110 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
6115 Magic Word: {{NUMBEROFFILES}}
6124 Magic Word: {{PAGENAME}}
6126 title=[[User:Ævar Arnfjörð Bjarmason]]
6130 <p>Ævar Arnfjörð Bjarmason
6135 Magic Word: {{PAGENAME}} with metacharacters
6137 title=[['foo & bar = baz']]
6141 <p><i>'foo & bar = baz'</i>
6146 Magic Word: {{PAGENAME}} with metacharacters (bug 26781)
6148 title=[[*RFC 1234 http://example.com/]]
6152 <p>*RFC 1234 http://example.com/
6157 Magic Word: {{PAGENAMEE}}
6159 title=[[User:Ævar Arnfjörð Bjarmason]]
6163 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
6168 Magic Word: {{PAGENAMEE}} with metacharacters (bug 26781)
6170 title=[[*RFC 1234 http://example.com/]]
6174 <p>*RFC_1234_http://example.com/
6179 Magic Word: {{REVISIONID}}
6188 Magic Word: {{SCRIPTPATH}}
6197 Magic Word: {{STYLEPATH}}
6206 Magic Word: {{SERVER}}
6210 <p><a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
6215 Magic Word: {{SERVERNAME}}
6224 Magic Word: {{SITENAME}}
6233 Case-sensitive magic words, when cased differently, should just be template transclusions
6240 <p><a href="/index.php?title=Template:CurrentMonth&action=edit&redlink=1" class="new" title="Template:CurrentMonth (page does not exist)">Template:CurrentMonth</a>
6241 <a href="/index.php?title=Template:Currentday&action=edit&redlink=1" class="new" title="Template:Currentday (page does not exist)">Template:Currentday</a>
6242 <a href="/index.php?title=Template:CURreNTweEK&action=edit&redlink=1" class="new" title="Template:CURreNTweEK (page does not exist)">Template:CURreNTweEK</a>
6243 <a href="/index.php?title=Template:CurrentHour&action=edit&redlink=1" class="new" title="Template:CurrentHour (page does not exist)">Template:CurrentHour</a>
6248 Case-insensitive magic words should still work with weird casing.
6258 <a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
6263 Namespace 1 {{ns:1}}
6272 Namespace 1 {{ns:01}}
6281 Namespace 0 {{ns:0}} (bug 4783)
6289 Namespace 0 {{ns:00}} (bug 4783)
6297 Namespace -1 {{ns:-1}}
6306 Namespace User {{ns:User}}
6315 Namespace User talk {{ns:User_talk}}
6324 Namespace User talk {{ns:uSeR tAlK}}
6333 Namespace File {{ns:File}}
6342 Namespace File {{ns:Image}}
6351 Namespace (lang=de) Benutzer {{ns:User}}
6362 Namespace (lang=de) Benutzer Diskussion {{ns:3}}
6368 <p>Benutzer Diskussion
6376 {{urlencode:hi world?!}}
6377 {{urlencode:hi world?!|WIKI}}
6378 {{urlencode:hi world?!|PATH}}
6379 {{urlencode:hi world?!|QUERY}}
6392 Magic links: internal link to RFC (bug 479)
6396 <p><a href="/index.php?title=RFC_123&action=edit&redlink=1" class="new" title="RFC 123 (page does not exist)">RFC 123</a>
6401 Magic links: RFC (bug 479)
6405 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
6410 Magic links: ISBN (bug 1937)
6414 <p><a href="/wiki/Special:BookSources/0306406152" class="internal mw-magiclink-isbn">ISBN 0-306-40615-2</a>
6419 Magic links: PMID incorrectly converts space to underscore
6423 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
6432 Nonexistent template
6434 {{thistemplatedoesnotexist}}
6436 <p><a href="/index.php?title=Template:Thistemplatedoesnotexist&action=edit&redlink=1" class="new" title="Template:Thistemplatedoesnotexist (page does not exist)">Template:Thistemplatedoesnotexist</a>
6441 Template with invalid target containing tags
6443 {{a<b>b</b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
6445 <p>{{a<b>b</b>|foo|a=b|a = b}}
6450 Template with invalid target containing unclosed tag
6452 {{a<b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
6454 <p>{{a<b>|foo|a=b|a = b}}</b>
6461 This is a test template
6469 <p>This is a test template
6474 Template with explicit namespace
6478 <p>This is a test template
6486 This is a test template with parameter {{{param}}}
6492 {{paramtest|param=foo}}
6494 <p>This is a test template with parameter foo
6499 Template:paramtestnum
6505 Template unnamed parameter
6507 {{paramtestnum|Main Page|the main page}}
6509 <p><a href="/wiki/Main_Page" title="Main Page">the main page</a>
6514 Template:templatesimple
6520 Template:templateredirect
6522 #redirect [[Template:templatesimple]]
6526 Template:templateasargtestnum
6532 Template:templateasargtest
6534 {{template{{{templ}}}}}
6538 Template:templateasargtest2
6544 Template with template name as unnamed argument
6546 {{templateasargtestnum|templatesimple}}
6553 Template with template name as argument
6555 {{templateasargtest|templ=simple}}
6562 Template with template name as argument (2)
6564 {{templateasargtest2|templ=templatesimple}}
6571 Template:templateasargtestdefault
6573 {{{{{templ|templatesimple}}}}}
6583 Template with default value
6585 {{templateasargtestdefault}}
6592 Template with default value (value set)
6594 {{templateasargtestdefault|templ=templa}}
6603 {{templateredirect}}
6610 Template with argument in separate line
6612 {{ templateasargtest |
6620 Template with complex template as argument
6623 param ={{ templateasargtest |
6626 <p>This is a test template with parameter (test)
6631 Template with thumb image (with link in description)
6634 param =[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]}}
6636 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>
6641 Template:complextemplate
6643 {{{1}}} {{paramtest|
6644 param ={{{param}}}}}
6648 Template with complex arguments
6651 param ={{ templateasargtest |
6652 templ = simple }}|[[Template:complextemplate|link]]}}
6654 <p><a href="/wiki/Template:Complextemplate" title="Template:Complextemplate">link</a> This is a test template with parameter (test)
6659 BUG 553: link with two variables in a piped link
6662 |[[{{{1}}}|{{{2}}}]]
6667 <td>[[{{{1}}}|{{{2}}}]]
6673 Magic variable as template parameter
6675 {{paramtest|param={{SITENAME}}}}
6677 <p>This is a test template with parameter MediaWiki
6684 [[{{{param}}}|link]]
6688 Template parameter as link source
6690 {{linktest|param=Main Page}}
6692 <p><a href="/wiki/Main_Page" title="Main Page">link</a>
6697 Template-generated attribute string (k='v')
6699 <span {{attr_str|id|v1}}>bar</span>
6701 <p><span id="v1">bar</span>
6708 including another template, {{paramtest|param={{{arg}}}}}
6712 Template passing argument to another template
6714 {{paramtest2|arg='hmm'}}
6716 <p>including another template, This is a test template with parameter 'hmm'
6727 Template as link source
6731 [[{{linktest2}}|Main Page]]
6733 [[{{linktest2}}]]Page
6735 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
6736 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
6737 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>Page
6755 Template infinite loop
6759 <p><span class="error">Template loop detected: <a href="/wiki/Template:Loop1" title="Template:Loop1">Template:Loop1</a></span>
6764 Template from main namespace
6783 BUG 529: Template with table, not included at beginning of line
6802 BUG 523: Template shouldn't eat newline (or add an extra one before table)
6822 BUG 41: Template parameters shown as broken links
6831 Template with targets containing wikilinks
6835 {{[[{{echo|foo}}]]}}
6837 {{{{echo|[[foo}}]]}}
6839 <p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
6840 </p><p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
6848 ''None'' of '''this''' should be
6850 but rather passed unmodified
6854 # hmm, fix this or just deprecate msgnw and document its behavior?
6860 {{msgnw:MSGNW test}}
6862 <p>''None'' of '''this''' should be
6864 but rather passed unmodified
6872 {{int:youhavenewmessages|lots of money|not!}}
6874 <p>You have lots of money (not!).
6881 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
6885 <includeonly> and <noinclude> being included
6896 <onlyinclude>Foo</onlyinclude>bar
6900 <onlyinclude> being included
6912 <onlyinclude>Foo</onlyinclude>bar<includeonly>zar</includeonly>
6916 <onlyinclude> and <includeonly> being included
6925 <includeonly> and <noinclude> on a page
6927 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
6934 Un-closed <noinclude>
6941 <onlyinclude> on a page
6943 <onlyinclude>Foo</onlyinclude>bar
6950 Un-closed <onlyinclude>
6957 Self-closed noinclude, includeonly, onlyinclude tags
6968 Unbalanced includeonly and noinclude tags
6972 |b</noinclude></noinclude>
6973 |c</noinclude></includeonly>
6974 |d</includeonly></includeonly>
6983 <td>c</includeonly>
6985 <td>d</includeonly></includeonly>
6991 Template:Includeonly section
6994 ==Includeonly section==
7000 Bug 6563: Edit link generation for section shown by <includeonly>
7002 {{includeonly section}}
7004 <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>
7005 <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>
7009 # Uses same input as the contents of [[Template:Includeonly section]]
7011 Bug 6563: Section extraction for section shown by <includeonly>
7016 ==Includeonly section==
7024 Bug 6563: Edit link generation for section suppressed by <includeonly>
7027 ==Includeonly section==
7031 <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>
7036 Bug 6563: Section extraction for section suppressed by <includeonly>
7041 ==Includeonly section==
7049 Un-closed <includeonly>
7055 # TODO: test with DOM fragment reuse!
7057 Parsoid: DOM fragment reuse
7059 parsoid=wt2wt,wt2html
7061 a{{echo|b<table></table>c}}d
7073 a<span typeof="mw:Transclusion">b</span>
7074 <table></table><span>c</span>d
7075 <p typeof="mw:Transclusion">ab</p>
7078 <p typeof="mw:Transclusion">a</p>
7084 ### <includeonly> and <noinclude> in attributes
7087 0. includeonly around the entire attribute
7089 <span <includeonly>id="v1"</includeonly><noinclude>id="v2"</noinclude>>bar</span>
7091 <p><span id="v2">bar</span>
7096 1. includeonly in html attr key
7098 <span <noinclude>id</noinclude><includeonly>about</includeonly>="foo">bar</span>
7100 <p><span id="foo">bar</span>
7105 2. includeonly in html attr value
7107 <span id="<noinclude>v1</noinclude><includeonly>v2</includeonly>">bar</span>
7108 <span id=<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>>bar</span>
7110 <p><span id="v1">bar</span>
7111 <span id="v1">bar</span>
7116 3. includeonly in part of an attr value
7118 <span style="color:<noinclude>red</noinclude><includeonly>blue</includeonly>;">bar</span>
7120 <p><span style="color:red;">bar</span>
7125 ### Testing parsing of templates where a template arg
7126 ### has the same name as the template itself.
7136 Templates: Template Name/Arg clash: 1. Use of positional param
7145 Templates: Template Name/Arg clash: 2. Use of named param
7154 Templates: Template Name/Arg clash: 3. Use of named param with empty input
7163 ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged
7167 Templates: 1. Simple use
7176 Templates: 2. Inside a block tag
7178 <div>{{echo|Foo}}</div>
7185 Templates: P-wrapping: 1a. Templates on consecutive lines
7196 Templates: P-wrapping: 1b. Templates on consecutive lines
7210 Templates: P-wrapping: 1c. Templates on consecutive lines
7213 {{echo|bar}} <div>baz</div>
7222 Templates: P-wrapping: 1d. Template preceded by comment-only line
7224 parsoid=wt2html,wt2wt
7230 <p typeof="mw:Transclusion">Bar
7235 Templates: Inline Text: 1. Multiple tmeplate uses
7237 {{echo|Foo}}bar{{echo|baz}}
7244 Templates: Inline Text: 2. Back-to-back template uses
7246 {{echo|Foo}}{{echo|bar}}
7253 Templates: Block Tags: 1. Multiple template uses
7255 {{echo|<div>Foo</div>}}<div>bar</div>{{echo|<div>baz</div>}}
7257 <div>Foo</div><div>bar</div><div>baz</div>
7262 Templates: Block Tags: 2. Back-to-back template uses
7264 {{echo|<div>Foo</div>}}{{echo|<div>bar</div>}}
7266 <div>Foo</div><div>bar</div>
7271 Templates: Links: 1. Simple example
7273 {{echo|[[Foo|bar]]}}
7275 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
7280 Templates: Links: 2. Generation of link href
7282 [[{{echo|Foo}}|bar]]
7284 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
7289 Templates: Links: 3. Generation of part of a link href
7291 [[Fo{{echo|o}}|bar]]
7295 [[Foo{{echo|bar}}baz]]
7297 [[Foo{{echo|bar}}|bar]]
7299 [[:Foo{{echo|bar}}]]
7301 [[:Foo{{echo|bar}}|bar]]
7303 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
7304 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
7305 </p><p><a href="/index.php?title=Foobarbaz&action=edit&redlink=1" class="new" title="Foobarbaz (page does not exist)">Foobarbaz</a>
7306 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
7307 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
7308 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
7313 Templates: Links: 4. Multiple templates generating link href
7315 [[{{echo|F}}{{echo|o}}ob{{echo|ar}}]]
7317 <p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
7322 Templates: Links: 5. Generation of link text
7324 [[Foo|{{echo|bar}}]]
7326 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
7331 Templates: Links: 5. Nested templates (only outermost template should be marked)
7333 {{echo|[[{{echo|Foo}}|bar]]}}
7335 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
7340 Templates: HTML Tag: 1. Generation of HTML attr. key
7342 <div {{echo|style}}="color:red;">foo</div>
7344 <div style="color:red;">foo</div>
7349 Templates: HTML Tag: 2. Generation of HTML attr. value
7351 <div style={{echo|'color:red;'}}>foo</div>
7353 <div style="color:red;">foo</div>
7358 Templates: HTML Tag: 3. Generation of HTML attr key and value
7360 <div {{echo|style}}={{echo|'color:red;'}}>foo</div>
7362 <div style="color:red;">foo</div>
7367 Templates: HTML Tag: 4. Generation of starting piece of HTML attr value
7369 <div title="{{echo|This is a long title}} with just one piece templated">foo</div>
7371 <div title="This is a long title with just one piece templated">foo</div>
7376 Templates: HTML Tag: 5. Generation of middle piece of HTML attr value
7378 <div title="This is a long title with just {{echo|one piece}} templated">foo</div>
7380 <div title="This is a long title with just one piece templated">foo</div>
7385 Templates: HTML Tag: 6. Generation of end piece of HTML attr value
7387 <div title="This is a long title with just one piece {{echo|templated}}">foo</div>
7389 <div title="This is a long title with just one piece templated">foo</div>
7394 Templates: HTML Tag: 7. Generation of partial attribute key string
7396 <div st{{echo|yle}}="color:red;">foo</div>
7398 <div style="color:red;">foo</div>
7403 Templates: HTML Tables: 1. Generating start of a HTML table
7405 {{echo|<table><tr><td>foo</td>}}</tr></table>
7407 <table><tr><td>foo</td></tr></table>
7412 Templates: HTML Tables: 2a. Generating middle of a HTML table
7414 <table><tr>{{echo|<td>foo</td>}}</tr></table>
7416 <table><tr><td>foo</td></tr></table>
7421 Templates: HTML Tables: 2b. Generating middle of a HTML table
7423 <table>{{echo|<tr><td>foo</td></tr>}}</table>
7425 <table><tr><td>foo</td></tr></table>
7430 Templates: HTML Tables: 3. Generating end of a HTML table
7432 <table><tr>{{echo|<td>foo</td></tr></table>}}
7434 <table><tr><td>foo</td></tr></table>
7439 Templates: HTML Tables: 4a. Generating a single tag of a HTML table
7441 {{echo|<table>}}<tr><td>foo</td></tr></table>
7443 <table><tr><td>foo</td></tr></table>
7448 Templates: HTML Tables: 4b. Generating a single tag of a HTML table
7450 <table>{{echo|<tr>}}<td>foo</td></tr></table>
7452 <table><tr><td>foo</td></tr></table>
7457 Templates: HTML Tables: 4c. Generating a single tag of a HTML table
7459 <table><tr>{{echo|<td>}}foo</td></tr></table>
7461 <table><tr><td>foo</td></tr></table>
7466 Templates: HTML Tables: 4d. Generating a single tag of a HTML table
7468 <table><tr><td>foo{{echo|</td>}}</tr></table>
7470 <table><tr><td>foo</td></tr></table>
7475 Templates: HTML Tables: 4e. Generating a single tag of a HTML table
7477 <table><tr><td>foo</td>{{echo|</tr>}}</table>
7479 <table><tr><td>foo</td></tr></table>
7484 Templates: HTML Tables: 4f. Generating a single tag of a HTML table
7486 <table><tr><td>foo</td></tr>{{echo|</table>}}
7488 <table><tr><td>foo</td></tr></table>
7493 Templates: HTML Tables: 5. Proper fostering of categories from inside
7495 parsoid=wt2html,wt2wt
7497 <table>[[Category:foo1]]<tr><td>foo</td></tr></table>
7498 <!--Two categories (Bug 50330)-->
7499 <table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>
7501 <link rel="mw:WikiLink/Category" href="./Category:Foo1"><table><tbody><tr><td>foo</td></tr></tbody></table>
7502 <!--Two categories (Bug 50330)-->
7503 <link rel="mw:WikiLink/Category" href="./Category:Bar1"><link rel="mw:WikiLink/Category" href="./Category:Bar2"><table><tbody><tr><td>foo</td></tr></tbody></table>
7507 Templates: Wiki Tables: 1a. Fostering of entire template content
7515 <tr><td></td></tr></table>
7520 Templates: Wiki Tables: 1b. Fostering of entire template content
7533 <tr><td></td></tr></table>
7538 Templates: Wiki Tables: 2. Fostering of partial template content
7548 <tr><td></td></tr></table>
7553 Templates: Wiki Tables: 3. td-content via multiple templates
7556 {{echo|{{pipe}}a}}{{echo|b}}
7567 Templates: Wiki Tables: 4. Templated tags, no content
7573 <tr><td></td></tr></table>
7578 Templates: Wiki Tables: 5. Templated tags, regular td-tags
7592 Templates: Wiki Tables: 6. Templated tags, templated td-tags
7606 Templates: Lists: Multi-line list-items via templates
7608 *{{echo|a {{nonexistent|
7610 *{{echo|b {{nonexistent|
7613 <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>
7614 </li><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>
7620 Templates: Ugly nesting: 1. Quotes opened/closed across templates (echo)
7622 {{echo|''a}}{{echo|b''c''d}}{{echo|''e}}
7624 <p><i>ab</i>c<i>d</i>e
7629 Templates: Ugly nesting: 2. Quotes opened/closed across templates (echo_with_span)
7630 (PHP parser generates misnested html)
7632 parsoid=wt2html,wt2wt
7634 {{echo_with_span|''a}}{{echo_with_span|b''c''d}}{{echo_with_span|''e}}
7636 <p><span typeof="mw:Transclusion"><i>a</i></span><i typeof="mw:Transclusion"><span>b</span></i><span>c</span><i>d</i><span>e</span></p>
7640 Templates: Ugly nesting: 3. Quotes opened/closed across templates (echo_with_div)
7641 (PHP parser generates misnested html)
7643 parsoid=wt2html,wt2wt
7645 {{echo_with_div|''a}}{{echo_with_div|b''c''d}}{{echo_with_div|''e}}
7647 <div typeof="mw:Transclusion"><i>a</i></div>
7648 <div typeof="mw:Transclusion"><i>b</i>c<i>d</i></div>
7649 <div typeof="mw:Transclusion">e</div>
7653 Templates: Ugly nesting: 4. Divs opened/closed across templates
7655 a<div>b{{echo|c</div>d}}e
7662 Templates: Ugly templates: 1. Navbox template parses badly leading to table misnesting
7668 |{{echo|foo</table>}}
7672 <table typeof="mw:Transclusion">
7675 <td>foo</td></tr></tbody></table><span>bar</span>
7679 Templates: Ugly templates: 2. Navbox template parses badly leading to table misnesting
7689 <td>1. {{echo|foo </table>}}</td>
7691 <td>2. {{echo|baz </table>}}</td>
7704 <table about="#mwt1" typeof="mw:Transclusion">
7709 <td >1. foo </td></tr></tbody></table></td>
7711 <td >2. baz </td></tr></tbody></table><span about="#mwt1">
7712 </span><span about="#mwt1">
7714 abc</span><span about="#mwt1">
7715 </span><span about="#mwt1">
7716 </span><span about="#mwt1">
7717 </span><span about="#mwt1">
7718 </span><span about="#mwt1">
7720 xyz</span><span about="#mwt1">
7721 </span><span about="#mwt1">
7726 Templates: Ugly templates: 3. newline-only template parameter
7735 # This looks like a bug: a single newline triggers p/br for some reason.
7737 Templates: Ugly templates: 4. newline-only template parameter inconsistency
7748 Parser Functions: 1. Simple example
7757 Parser Functions: 2. Nested use (only outermost should be marked up)
7766 ### Pre-save transform tests
7769 pre-save transform: subst:
7775 This is a test template
7779 pre-save transform: normal template
7789 pre-save transform: nonexistent template
7793 {{thistemplatedoesnotexist}}
7795 {{thistemplatedoesnotexist}}
7800 pre-save transform: subst magic variables
7809 # This is bug 89, which I fixed. -- wtm
7811 pre-save transform: subst: templates with parameters
7815 {{subst:paramtest|param="something else"}}
7817 This is a test template with parameter "something else"
7823 <nowiki>'''not wiki'''</nowiki>
7827 pre-save transform: nowiki in subst (bug 1188)
7831 {{subst:nowikitest}}
7833 <nowiki>'''not wiki'''</nowiki>
7838 Template:commenttest
7840 This template has <!-- a comment --> in it.
7844 pre-save transform: comment in subst (bug 1936)
7848 {{subst:commenttest}}
7850 This template has <!-- a comment --> in it.
7854 pre-save transform: unclosed tag
7858 <nowiki>'''not wiki'''
7860 <nowiki>'''not wiki'''
7864 pre-save transform: mixed tag case
7868 <NOwiki>'''not wiki'''</noWIKI>
7870 <NOwiki>'''not wiki'''</noWIKI>
7874 pre-save transform: unclosed comment in <nowiki>
7878 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
7880 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
7883 # Leading @ in this template definition works around a limitation
7884 # in parsoid's parserTests which otherwise strips the <span> from the
7885 # result (confusing it for a template wrapper)
7889 @<span onmouseover="alert('crap')">Oh no</span>
7893 (confirming safety of fix for subst bug 1936)
7895 {{Template:dangerous}}
7897 <p>@<span>Oh no</span>
7902 pre-save transform: comment containing gallery (bug 5024)
7906 <!-- <gallery>data</gallery> -->
7908 <!-- <gallery>data</gallery> -->
7912 pre-save transform: comment containing extension
7916 <!-- <tag>data</tag> -->
7918 <!-- <tag>data</tag> -->
7922 pre-save transform: comment containing nowiki
7926 <!-- <nowiki>data</nowiki> -->
7928 <!-- <nowiki>data</nowiki> -->
7932 pre-save transform: <noinclude> in subst (bug 3298)
7942 pre-save transform: <onlyinclude> in subst (bug 3298)
7954 {{<includeonly>subst:</includeonly>Includes}}
7958 Template:SafeSubstTest
7960 {{<includeonly>safesubst:</includeonly>Includes}}
7964 bug 22297: safesubst: works during PST
7968 {{subst:SafeSubstTest}}{{safesubst:SubstTest}}
7974 bug 22297: safesubst: works during normal parse
7983 subst: does not work during normal parse
7987 <p>{{subst:Includes}}
7992 pre-save transform: context links ("pipe trick")
7996 [[Article (context)|]]
7999 [[Bar:Article (context)|]]
8000 [[:Bar:Article (context)|]]
8002 [[|Article (context)]]
8006 [[Article (context)|Article]]
8007 [[Bar:Article|Article]]
8008 [[:Bar:Article|Article]]
8009 [[Bar:Article (context)|Article]]
8010 [[:Bar:Article (context)|Article]]
8012 [[Article (context)]]
8013 [[Bar:X (Y) Z|X (Y) Z]]
8014 [[:Bar:X (Y) Z|X (Y) Z]]
8018 pre-save transform: context links ("pipe trick") with interwiki prefix
8022 [[interwiki:Article|]]
8023 [[:interwiki:Article|]]
8024 [[interwiki:Bar:Article|]]
8025 [[:interwiki:Bar:Article|]]
8027 [[interwiki:Article|Article]]
8028 [[:interwiki:Article|Article]]
8029 [[interwiki:Bar:Article|Bar:Article]]
8030 [[:interwiki:Bar:Article|Bar:Article]]
8034 pre-save transform: context links ("pipe trick") with parens in title
8036 pst title=[[Somearticle (context)]]
8040 [[Article (context)|Article]]
8044 pre-save transform: context links ("pipe trick") with comma in title
8046 pst title=[[Someplace, Somewhere]]
8049 [[Otherplace, Elsewhere|]]
8050 [[Otherplace, Elsewhere, Anywhere|]]
8052 [[Otherplace, Somewhere|Otherplace]]
8053 [[Otherplace, Elsewhere|Otherplace]]
8054 [[Otherplace, Elsewhere, Anywhere|Otherplace]]
8058 pre-save transform: context links ("pipe trick") with parens and comma
8060 pst title=[[Someplace (IGNORED), Somewhere]]
8063 [[Otherplace (place), Elsewhere|]]
8065 [[Otherplace, Somewhere|Otherplace]]
8066 [[Otherplace (place), Elsewhere|Otherplace]]
8070 pre-save transform: context links ("pipe trick") with comma and parens
8072 pst title=[[Who, me? (context)]]
8075 [[Me, Myself, and I (1937 song)|]]
8077 [[Yes, you. (context)|Yes, you.]]
8078 [[Me, Myself, and I (1937 song)|Me, Myself, and I]]
8082 pre-save transform: context links ("pipe trick") with namespace
8084 pst title=[[Ns:Somearticle]]
8088 [[Ns:Article|Article]]
8092 pre-save transform: context links ("pipe trick") with namespace and parens
8094 pst title=[[Ns:Somearticle (context)]]
8098 [[Ns:Article (context)|Article]]
8102 pre-save transform: context links ("pipe trick") with namespace and comma
8104 pst title=[[Ns:Somearticle, Context, Whatever]]
8108 [[Ns:Article, Context, Whatever|Article]]
8112 pre-save transform: context links ("pipe trick") with namespace, comma and parens
8114 pst title=[[Ns:Somearticle, Context (context)]]
8118 [[Ns:Article (context)|Article]]
8122 pre-save transform: context links ("pipe trick") with namespace, parens and comma
8124 pst title=[[Ns:Somearticle (IGNORED), Context]]
8128 [[Ns:Article, Context|Article]]
8132 pre-save transform: context links ("pipe trick") with full-width parens and no space (Japanese and Chinese style, bug 30149)
8136 [[Article(context)|]]
8137 [[Bar:Article(context)|]]
8138 [[:Bar:Article(context)|]]
8139 [[|Article(context)]]
8143 [[Article(context)|Article]]
8144 [[Bar:Article(context)|Article]]
8145 [[:Bar:Article(context)|Article]]
8146 [[Article(context)]]
8148 [[:Bar:X(Y)Z|X(Y)Z]]
8152 pre-save transform: context links ("pipe trick") with full-width parens and space (Japanese and Chinese style, bug 30149)
8156 [[Article (context)|]]
8157 [[Bar:Article (context)|]]
8158 [[:Bar:Article (context)|]]
8159 [[|Article (context)]]
8163 [[Article (context)|Article]]
8164 [[Bar:Article (context)|Article]]
8165 [[:Bar:Article (context)|Article]]
8166 [[Article (context)]]
8167 [[Bar:X (Y) Z|X (Y) Z]]
8168 [[:Bar:X (Y) Z|X (Y) Z]]
8172 pre-save transform: context links ("pipe trick") with parens and no space (Korean style, bug 30149)
8176 [[Article(context)|]]
8177 [[Bar:Article(context)|]]
8178 [[:Bar:Article(context)|]]
8179 [[|Article(context)]]
8183 [[Article(context)|Article]]
8184 [[Bar:Article(context)|Article]]
8185 [[:Bar:Article(context)|Article]]
8186 [[Article(context)]]
8188 [[:Bar:X(Y)Z|X(Y)Z]]
8192 pre-save transform: context links ("pipe trick") with commas (bug 21660)
8196 [[Article (context), context|]]
8197 [[Article (context),context|]]
8198 [[Bar:Article (context), context|]]
8199 [[Bar:Article (context),context|]]
8200 [[:Bar:Article (context), context|]]
8201 [[:Bar:Article (context),context|]]
8203 [[Article (context), context|Article]]
8204 [[Article (context),context|Article]]
8205 [[Bar:Article (context), context|Article]]
8206 [[Bar:Article (context),context|Article]]
8207 [[:Bar:Article (context), context|Article]]
8208 [[:Bar:Article (context),context|Article]]
8212 pre-save transform: trim trailing empty lines
8216 Empty lines are trimmed
8222 Empty lines are trimmed
8226 pre-save transform: Signature expansion
8231 * <noinclude>~~~</noinclude>
8232 * <includeonly>~~~</includeonly>
8233 * <onlyinclude>~~~</onlyinclude>
8235 * [[Special:Contributions/127.0.0.1|127.0.0.1]]
8236 * <noinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</noinclude>
8237 * <includeonly>[[Special:Contributions/127.0.0.1|127.0.0.1]]</includeonly>
8238 * <onlyinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</onlyinclude>
8243 pre-save transform: Signature expansion in nowiki tags (bug 93)
8249 <nowiki>~~~~</nowiki>
8251 <includeonly><nowiki>~~~~</nowiki></includeonly>
8253 <noinclude><nowiki>~~~~</nowiki></noinclude>
8255 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
8257 {{subst:Foo}} shall be converted to FOO
8259 As well as inside noinclude/onlyinclude
8260 <noinclude>{{subst:Foo}}</noinclude>
8261 <onlyinclude>{{subst:Foo}}</onlyinclude>
8263 But not inside includeonly
8264 <includeonly>{{subst:Foo}}</includeonly>
8268 <nowiki>~~~~</nowiki>
8270 <includeonly><nowiki>~~~~</nowiki></includeonly>
8272 <noinclude><nowiki>~~~~</nowiki></noinclude>
8274 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
8276 FOO shall be converted to FOO
8278 As well as inside noinclude/onlyinclude
8279 <noinclude>FOO</noinclude>
8280 <onlyinclude>FOO</onlyinclude>
8282 But not inside includeonly
8283 <includeonly>{{subst:Foo}}</includeonly>
8287 Parsoid: Recognize nowiki with trailing space in tags
8291 <nowiki ><div>[[foo]]</nowiki >
8299 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
8306 Parsoid: Recognize nowiki with odd capitalization
8310 <noWikI ><div>[[foo]]</Nowiki >
8312 <p><span typeof="mw:Nowiki"><div>[[foo]]</span></p>
8317 Parsoid: Escape nowiki with trailing space in tags
8321 <nowiki > foo </nowiki >
8327 <p><nowiki > foo </nowiki ></p>
8328 <p>a<nowiki />b</p>
8329 <p>c<nowiki/ >d</p>
8333 Parsoid: Escape weird noWikI capitalizations
8337 <noWikI > foo </NoWikI >
8339 <p><noWikI > foo </NoWikI ></p>
8343 ### Message transform tests
8346 message transform: magic variables
8356 message transform: should not transform wiki markup
8366 message transform: <noinclude> in transcluded template (bug 4926)
8376 message transform: <onlyinclude> in transcluded template (bug 4926)
8386 {{#special:}} page name, known
8390 {{#special:Recentchanges}}
8392 Special:RecentChanges
8396 {{#special:}} page name with subpage, known
8400 {{#special:Recentchanges/param}}
8402 Special:RecentChanges/param
8406 {{#special:}} page name, unknown
8410 {{#special:foobar nonexistent}}
8412 Special:Foobar nonexistent
8416 {{#speciale:}} page name, known
8420 {{#speciale:Recentchanges}}
8422 Special:RecentChanges
8426 {{#speciale:}} page name with subpage, known
8430 {{#speciale:Recentchanges/param}}
8432 Special:RecentChanges/param
8436 {{#speciale:}} page name, unknown
8440 {{#speciale:foobar nonexistent}}
8442 Special:Foobar_nonexistent
8448 ### For Parsoid-specific tests, see
8449 #### http://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
8456 [[Image:foobar.jpg]]
8458 <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>
8463 Simple image (parsoid)
8467 [[Image:foobar.jpg]]
8469 <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>
8474 Simple image (using File: namespace, now canonical) (php)
8480 <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>
8485 Simple image (using File: namespace, now canonical) (parsoid)
8491 <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>
8496 Right-aligned image (php)
8500 [[Image:foobar.jpg|right]]
8502 <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>
8507 Right-aligned image (parsoid)
8511 [[File:Foobar.jpg|right]]
8513 <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>
8517 Image with caption (php)
8521 [[File:Foobar.jpg|right|Caption text]]
8523 <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>
8528 Image with caption (parsoid)
8532 [[File:Foobar.jpg|right|Caption text]]
8534 <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>
8538 Image with empty attribute (php)
8542 [[File:Foobar.jpg|right||Caption text]]
8544 <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>
8549 Image with empty attribute (parsoid)
8553 [[File:Foobar.jpg|right||Caption text]]
8555 <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>
8559 Image with attributes from template (php)
8563 [[File:Foobar.jpg|{{image_attribs}}]]
8565 <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>
8570 Image with attributes from template (parsoid)
8574 [[File:Foobar.jpg|{{image_attribs}}]]
8576 <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>
8580 Image with link tails (php)
8584 123[[File:Foobar.jpg]]456
8585 123[[File:Foobar.jpg|right]]456
8586 123[[File:Foobar.jpg|thumb]]456
8588 <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
8590 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
8591 123<div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Foobar.jpg" 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></div></div></div>456
8596 Image with link tails (parsoid)
8600 123[[File:Foobar.jpg]]456
8601 123[[File:Foobar.jpg|right]]456
8602 123[[File:Foobar.jpg|thumb]]456
8604 <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>
8605 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
8606 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="20" width="180"></a></figure>456
8610 Image with multiple captions -- only last one is accepted (php)
8614 [[File:Foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
8616 <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>
8621 Image with multiple captions -- only last one is accepted (parsoid)
8625 [[File:Foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
8627 <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>
8631 Image with width attribute at different positions (php)
8635 [[File:Foobar.jpg|200px|right|Caption]]
8636 [[File:Foobar.jpg|right|200px|Caption]]
8637 [[File:Foobar.jpg|right|Caption|200px]]
8639 <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>
8640 <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>
8641 <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>
8646 Image with width attribute at different positions (parsoid)
8650 [[File:Foobar.jpg|200px|right|Caption]]
8651 [[File:Foobar.jpg|right|200px|Caption]]
8652 [[File:Foobar.jpg|right|Caption|200px]]
8654 <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>
8655 <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>
8656 <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>
8660 Image with link parameter, wiki target (php)
8664 [[File:Foobar.jpg|link=Main Page]]
8666 <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>
8671 Image with link parameter, wiki target (parsoid)
8675 [[File:Foobar.jpg|link=Main Page]]
8677 <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>
8681 Image with link parameter, URL target (php)
8685 [[File:Foobar.jpg|link=http://example.com/]]
8687 <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>
8691 # parsoid bug 49293 (part 1)
8693 Image with link parameter, URL target (parsoid)
8697 [[File:Foobar.jpg|link=http://example.com/]]
8699 <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>
8703 Image with link parameter, protocol-less URL target (php)
8707 [[File:Foobar.jpg|link=//example.com/]]
8709 <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>
8713 # parsoid bug 49293 (part 2)
8715 Image with link parameter, protocol-less URL target (parsoid)
8719 [[File:Foobar.jpg|link=//example.com/]]
8721 <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>
8725 Image with link parameter, wgExternalLinkTarget
8727 [[Image:foobar.jpg|link=http://example.com/]]
8729 wgExternalLinkTarget='foobar'
8731 <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>
8736 Image with link parameter, wgNoFollowLinks set to false
8738 [[Image:foobar.jpg|link=http://example.com/]]
8740 wgNoFollowLinks=false
8742 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8747 Image with link parameter, wgNoFollowDomainExceptions
8749 [[Image:foobar.jpg|link=http://example.com/]]
8751 wgNoFollowDomainExceptions='example.com'
8753 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
8758 Image with link parameter, wgExternalLinkTarget, unnamed parameter
8760 [[Image:foobar.jpg|link=http://example.com/|Title]]
8762 wgExternalLinkTarget='foobar'
8764 <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>
8769 Image with empty link parameter (php)
8773 [[File:Foobar.jpg|link=]]
8775 <p><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" />
8780 Image with empty link parameter (parsoid)
8784 [[File:Foobar.jpg|link=]]
8786 <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>
8790 Image with link parameter (wiki target) and unnamed parameter (php)
8794 [[File:Foobar.jpg|link=Main Page|Title]]
8796 <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>
8801 Image with link parameter (wiki target) and unnamed parameter (parsoid)
8805 [[File:Foobar.jpg|link=Main Page|Title]]
8807 <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>
8811 Image with link parameter (URL target) and unnamed parameter (php)
8815 [[File:Foobar.jpg|link=http://example.com/|Title]]
8817 <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>
8822 Image with link parameter (URL target) and unnamed parameter (parsoid)
8826 [[File:Foobar.jpg|link=http://example.com/|Title]]
8828 <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>
8832 Thumbnail image with link parameter
8836 [[Image:foobar.jpg|thumb|link=http://example.com/|Title]]
8838 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="http://example.com/"><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>Title</div></div></div>
8843 Manually-specified thumbnail image
8847 [[Image:Foobar.jpg|thumb=Thumb.png|Title]]
8849 <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>
8854 Manually-specified thumbnail image with explicit link to wiki page
8858 [[Image:Foobar.jpg|thumb=Thumb.png|link=Main Page|Title]]
8860 <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>
8865 Manually-specified thumbnail image with explicit link to url
8869 [[Image:Foobar.jpg|thumb=Thumb.png|link=http://example.com|Title]]
8871 <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>
8876 Manually-specified thumbnail image with explicit no link
8880 [[Image:Foobar.jpg|thumb=Thumb.png|link=|Title]]
8882 <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>
8887 Manually-specified thumbnail image with explicit link and alt text
8891 [[Image:Foobar.jpg|thumb=Thumb.png|link=Main Page|alt=alttext|Title]]
8893 <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>
8898 Image with frame and link
8900 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]]]
8902 <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>
8907 Image with frame and link and explicit alt
8909 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]|alt=Altitude]]
8911 <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>
8916 Image with wiki markup in implicit alt
8918 [[Image:Foobar.jpg|testing '''bold''' in alt]]
8920 <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>
8925 Image with wiki markup in explicit alt
8927 [[Image:Foobar.jpg|alt=testing '''bold''' in alt]]
8929 <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>
8934 Link to image page- image page normally doesn't exists, hence edit link
8935 Add test with existing image page
8936 #<p><a href="/wiki/File:Test" title="Image:Test">Image:test</a>
8940 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">Image:test</a>
8945 bug 18784 Link to non-existent image page with caption should use caption as link text
8947 [[:Image:test|caption]]
8949 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">caption</a>
8954 Frameless image caption with a free URL
8956 [[Image:foobar.jpg|http://example.com]]
8958 <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>
8963 Thumbnail image caption with a free URL
8965 [[Image:foobar.jpg|thumb|http://example.com]]
8967 <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 rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
8972 Thumbnail image caption with a free URL and explicit alt
8974 [[Image:foobar.jpg|thumb|http://example.com|alt=Alteration]]
8976 <div class="thumb tright"><div class="thumbinner" style="width:182px;"><a href="/wiki/File:Foobar.jpg" class="image"><img alt="Alteration" src="http://example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" width="180" height="20" class="thumbimage" 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 rel="nofollow" class="external free" href="http://example.com">http://example.com</a></div></div></div>
8981 SVG thumbnails with no language set
8984 [[File:Foobar.svg|thumb|width=200]]
8986 <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="180" 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>width=200</div></div></div>
8991 SVG thumbnails with language de
8994 [[File:Foobar.svg|thumb|width=200|lang=de]]
8996 <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="180" 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>width=200</div></div></div>
9001 SVG thumbnails with invalid language code
9004 [[File:Foobar.svg|thumb|width=200|lang=invalid.language.code]]
9006 <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="180" 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>
9011 BUG 1887: A ISBN with a thumbnail
9013 [[Image:foobar.jpg|thumb|ISBN 1235467890]]
9015 <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>
9020 BUG 1887: A RFC with a thumbnail
9022 [[Image:foobar.jpg|thumb|This is RFC 12354]]
9024 <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>
9029 BUG 1887: A mailto link with a thumbnail
9031 [[Image:foobar.jpg|thumb|Please mailto:nobody@example.com]]
9033 <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>
9037 # Pending resolution to bug 368
9039 BUG 648: Frameless image caption with a link
9041 [[Image:foobar.jpg|text with a [[link]] in it]]
9043 <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>
9048 BUG 648: Frameless image caption with a link (suffix)
9050 [[Image:foobar.jpg|text with a [[link]]foo in it]]
9052 <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>
9057 BUG 648: Frameless image caption with an interwiki link
9059 [[Image:foobar.jpg|text with a [[MeatBall:Link]] in it]]
9061 <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>
9066 BUG 648: Frameless image caption with a piped interwiki link
9068 [[Image:foobar.jpg|text with a [[MeatBall:Link|link]] in it]]
9070 <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>
9075 Escape HTML special chars in image alt text
9077 [[Image:foobar.jpg|& < > "]]
9079 <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>
9084 BUG 499: Alt text should have Ӓ, not &1234;
9086 [[Image:foobar.jpg|♀]]
9088 <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>
9093 Broken image caption with link
9095 [[Image:Foobar.jpg|thumb|This is a broken caption. But [[Main Page|this]] is just an ordinary link.
9097 <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.
9102 Image caption containing another image
9104 [[Image:Foobar.jpg|thumb|This is a caption with another [[Image:icon.png|image]] inside it!]]
9106 <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="/index.php?title=Special:Upload&wpDestFile=Icon.png" class="new" title="File:Icon.png">image</a> inside it!</div></div></div>
9111 Image caption containing a newline
9113 [[Image:Foobar.jpg|This
9116 <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>
9121 Parsoid: Image caption containing leading space
9122 (The leading space should not trigger nowiki escaping in wt2wt mode)
9124 [[Image:Foobar.jpg|thumb| bar]]
9126 <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>
9131 Bug 3090: External links other than http: in image captions
9133 [[Image:Foobar.jpg|thumb|200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
9135 <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>
9142 [[Image:foobar.jpg|a|class=b]]
9144 <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>
9149 Localized image handling (1).
9153 [[Archivo:Foobar.jpg|izquierda|enlace=foo|caption]]
9155 <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>
9160 Localized image handling (2).
9164 [[Archivo:Foobar.jpg|miniatura|izquierda|enlace=foo|caption]]
9166 <div class="thumb tleft"><div class="thumbinner" style="width:182px;"><a href="/wiki/Foo" title="Foo"><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/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>
9171 "border", "frameless" and "class" attributes on an image.
9173 [[File:Foobar.jpg|frameless|border|class=extra|caption]]
9175 <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" class="extra thumbborder" 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>
9182 #REDIRECT [[File:Barfoo.jpg]]
9188 [[Image:Barfoo.jpg]]
9190 <p><a href="/wiki/File:Barfoo.jpg" title="File:Barfoo.jpg">File:Barfoo.jpg</a>
9195 Missing image with uploads disabled
9199 [[Image:Foobaz.jpg]]
9201 <p><a href="/wiki/File:Foobaz.jpg" title="File:Foobaz.jpg">File:Foobaz.jpg</a>
9205 # Parsoid-specific testing for images
9206 # http://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec#Images
9207 # Currently imperfect due to a flaw in the Parsoid testrunner
9209 # THESE TESTS SHOULD BE MOVED UP and merged with the php-specific
9213 Parsoid-specific image handling - simple image with size and middle alignment
9217 [[Image:Foobar.jpg|50px|middle]]
9220 <span class="mw-valign-middle" typeof="mw:Image">
9221 <a href="File:Foobar.jpg">
9222 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
9229 Parsoid-specific image handling - simple image with both sizes, a baseline alignment, and a caption
9233 [[Image:Foobar.jpg|500x10px|baseline|caption]]
9236 <span class="mw-valign-baseline" typeof="mw:Image" data-mw="{"caption":"caption"}">
9237 <a href="File:Foobar.jpg">
9238 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/89px-Foobar.jpg" height="10" width="89">
9245 Parsoid-specific image handling - simple image with border and size spec
9249 [[Image:Foobar.jpg|50px|border|caption]]
9252 <span class="mw-image-border" typeof="mw:Image" data-mw="{"caption":"caption"}">
9253 <a href="File:Foobar.jpg">
9254 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50">
9261 Parsoid-specific image handling - thumbnail with halign, valign, and caption
9265 [[Image:Foobar.jpg|thumb|left|baseline|caption content]]
9267 <figure class="mw-default-size mw-halign-left mw-valign-baseline" typeof="mw:Image/Thumb">
9268 <a href="File:Foobar.jpg">
9269 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/180px-Foobar.jpg" height="21" width="180" />
9271 <figcaption>caption content</figcaption>
9276 Parsoid-specific image handling - thumbnail with specific size, halign, valign, and caption
9280 [[Image:Foobar.jpg|thumb|50x50px|right|middle|caption]]
9282 <figure class="mw-halign-right mw-valign-middle" typeof="mw:Image/Thumb">
9283 <a href="File:Foobar.jpg">
9284 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/50px-Foobar.jpg" height="6" width="50" />
9286 <figcaption>caption</figcaption>
9291 Parsoid-specific image handling - framed image with specific size and caption
9295 [[Image:Foobar.jpg|500x50px|frame|caption]]
9297 <figure typeof="mw:Image/Frame">
9298 <a href="File:Foobar.jpg">
9299 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/442px-Foobar.jpg" height="50" width="442" />
9301 <figcaption>caption</figcaption>
9306 Parsoid-specific image handling - framed image with specific size, halign, valign, and caption
9310 [[Image:Foobar.jpg|500x50px|frame|left|baseline|caption]]
9312 <figure class="mw-halign-left mw-valign-baseline" typeof="mw:Image/Frame">
9313 <a href="File:Foobar.jpg">
9314 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/442px-Foobar.jpg" height="50" width="442" />
9316 <figcaption>caption</figcaption>
9321 Parsoid-specific image handling - frameless image with specific size, border, and caption
9325 [[Image:Foobar.jpg|frameless|500x50px|border|caption]]
9328 <span class="mw-image-border" typeof="mw:Image/Frameless" data-mw="{"caption":"caption"}">
9329 <a href="File:Foobar.jpg">
9330 <img resource="./File:Foobar.jpg" src="//example.com/images/thumb/3/3a/Foobar.jpg/442px-Foobar.jpg" height="50" width="442" />
9336 #Parsoid-specific image handling - simple image with a formatted caption
9340 #[[Image:Foobar.jpg|<table><tr><td>a</td><td>b</td></tr><tr><td>c</td></tr></table>]]
9343 #<span typeof="mw:Image">
9344 #<a class="mw-default-size" href="Image:Foobar.jpg">
9345 #<img alt="Foobar.jpg" class="mw-default-size" src="http://example.com/images/3/3a/Foobar.jpg" height="220" width="1941">
9356 Subpage test/subpage
9364 subpage title=[[Subpage test]]
9368 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a>
9373 Subpage noslash link
9375 subpage title=[[Subpage test]]
9379 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">subpage</a>
9383 # TODO: make this PHP-parser compatible!
9385 Relative subpage noslash link
9387 parsoid=wt2wt,wt2html,html2html
9388 subpage title=[[Subpage test/1/2/3/4]]
9394 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage/">subpage</a></p>
9395 <p><a rel="mw:WikiLink" href="Subpage_test/1/2/subpage">Subpage_test/1/2/subpage</a></p>
9398 # TODO: make this PHP-parser compatible!
9400 Parsoid: dot-slash prefixed wikilinks
9402 parsoid=wt2wt,wt2html,html2html
9410 <p><a rel="mw:WikiLink" href="./Foo">foo</a></p>
9411 <p><a rel="mw:WikiLink" href="./Bar">bar</a></p>
9412 <p><a rel="mw:WikiLink" href="./Baz/">baz/</a></p>
9420 <p><a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a>
9425 BUG 561: {{/Subpage}}
9427 subpage title=[[Page]]
9431 <p><a href="/index.php?title=Page/Subpage&action=edit&redlink=1" class="new" title="Page/Subpage (page does not exist)">Page/Subpage</a>
9439 Category:MediaWiki User's Guide
9447 [[:Category:MediaWiki User's Guide]]
9449 <p><a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">Category:MediaWiki User's Guide</a>
9458 [[Category:MediaWiki User's Guide]]
9460 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
9464 PAGESINCATEGORY invalid title fatal (r33546 fix)
9466 {{PAGESINCATEGORY:<bogus>}}
9473 Category with different sort key
9477 [[Category:MediaWiki User's Guide|Foo]]
9479 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
9483 Category with identical sort key
9487 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
9489 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
9493 Category with empty sort key
9498 [[Category:MediaWiki User's Guide|]]
9500 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
9504 Category with empty sort key and parentheses
9509 [[Category:Foo (bar)|]]
9511 [[Category:Foo (bar)|Foo]]
9515 Category with link tail
9520 123[[Category:Foo]]456
9522 123[[Category:Foo]]456
9526 Category with template
9531 [[Category:{{echo|Foo}}]]
9533 [[Category:{{echo|Foo}}]]
9537 Category with template in sort key
9542 [[Category:Foo|{{echo|Bar}}]]
9544 [[Category:Foo|{{echo|Bar}}]]
9548 Category with template in sort key and title
9553 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
9555 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
9559 Category / paragraph interactions
9561 Foo [[Category:Baz]] Bar
9563 Foo [[Category:Baz]]
9571 [[Category:Baz]] Bar
9584 {{echo|[[Category:Baz]]}}
9599 Parsoid: Serialize link to category page with colon escape
9605 [[:Category:Foo|Bar]]
9608 <a rel="mw:WikiLink" href="Category:Foo">Category:Foo</a>
9609 <a rel="mw:WikiLink" href="Category:Foo">Bar</a>
9614 Parsoid: Link prefix/suffixes aren't applied to category links
9616 parsoid=wt2html,wt2wt,html2html
9621 <p>x<link rel="mw:WikiLink/Category" href="Category:Foo">y</p>
9625 Parsoid: Serialize link to file page with colon escape
9631 [[:File:Foo.png|Bar]]
9634 <a rel="mw:WikiLink" href="File:Foo.png">File:Foo.png</a>
9635 <a rel="mw:WikiLink" href="File:Foo.png">Bar</a>
9640 Parsoid: Serialize a genuine category link without colon escape
9645 [[Category:Foo|Bar]]
9647 <link rel="mw:WikiLink/Category" href="Category:Foo">
9648 <link rel="mw:WikiLink/Category" href="Category:Foo#Bar">
9652 ### Inter-language links
9655 Inter-language links
9661 [[zh:食品]]
9663 es:Alimento fr:Nourriture zh:食品
9667 Duplicate interlanguage links (bug 24502)
9683 Basic section headings
9690 ===Smaller headline===
9693 <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>
9696 <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>
9699 <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>
9705 Section headings with TOC
9708 === Subheadline 1 ===
9709 ===== Skipping a level =====
9710 ====== Skipping a level ======
9714 ===Another headline===
9716 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9718 <li class="toclevel-1 tocsection-1"><a href="#Headline_1"><span class="tocnumber">1</span> <span class="toctext">Headline 1</span></a>
9720 <li class="toclevel-2 tocsection-2"><a href="#Subheadline_1"><span class="tocnumber">1.1</span> <span class="toctext">Subheadline 1</span></a>
9722 <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>
9724 <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>
9731 <li class="toclevel-1 tocsection-5"><a href="#Headline_2"><span class="tocnumber">2</span> <span class="toctext">Headline 2</span></a>
9733 <li class="toclevel-2 tocsection-6"><a href="#Another_headline"><span class="tocnumber">2.1</span> <span class="toctext">Another headline</span></a></li>
9738 <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>
9739 <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>
9740 <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>
9741 <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>
9742 <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>
9745 <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>
9749 # perl -e 'print "="x$_," Level $_ heading","="x$_,"\n" for 1..10'
9751 Handling of sections up to level 6 and beyond
9754 == Level 2 Heading==
9755 === Level 3 Heading===
9756 ==== Level 4 Heading====
9757 ===== Level 5 Heading=====
9758 ====== Level 6 Heading======
9759 ======= Level 7 Heading=======
9760 ======== Level 8 Heading========
9761 ========= Level 9 Heading=========
9762 ========== Level 10 Heading==========
9764 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9766 <li class="toclevel-1 tocsection-1"><a href="#Level_1_Heading"><span class="tocnumber">1</span> <span class="toctext">Level 1 Heading</span></a>
9768 <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>
9770 <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>
9772 <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>
9774 <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>
9776 <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>
9777 <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>
9778 <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>
9779 <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>
9780 <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>
9793 <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>
9794 <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>
9795 <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>
9796 <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>
9797 <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>
9798 <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>
9799 <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>
9800 <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>
9801 <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>
9802 <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>
9807 TOC regression (bug 9764)
9811 ==== title 1.1.1 ====
9816 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9818 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
9820 <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>
9822 <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>
9825 <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>
9828 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
9830 <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>
9835 <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>
9836 <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>
9837 <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>
9838 <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>
9839 <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>
9840 <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>
9845 TOC with wgMaxTocLevel=3 (bug 6204)
9851 ==== title 1.1.1 ====
9856 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9858 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
9860 <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>
9861 <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>
9864 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
9866 <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>
9871 <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>
9872 <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>
9873 <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>
9874 <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>
9875 <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>
9876 <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>
9881 TOC with wgMaxTocLevel=3 and two level four headings (bug 6204)
9887 ====Section 1.1.1====
9888 ====Section 1.1.1.1====
9891 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9893 <li class="toclevel-1 tocsection-1"><a href="#Section_1"><span class="tocnumber">1</span> <span class="toctext">Section 1</span></a>
9895 <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>
9898 <li class="toclevel-1 tocsection-5"><a href="#Section_2"><span class="tocnumber">2</span> <span class="toctext">Section 2</span></a></li>
9901 <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>
9902 <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>
9903 <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>
9904 <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>
9905 <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>
9911 Resolving duplicate section names
9916 <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>
9917 <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>
9922 Resolving duplicate section names with differing case (bug 10721)
9927 <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>
9928 <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>
9940 Template with sections, __NOTOC__
9947 <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>
9948 <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>
9949 <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>
9950 <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>
9955 __NOEDITSECTION__ keyword
9961 <h2><span class="mw-headline" id="Section_1">Section 1</span></h2>
9962 <h2><span class="mw-headline" id="Section_2">Section 2</span></h2>
9967 Link inside a section heading
9969 ==Section with a [[Main Page|link]] in it==
9971 <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>
9976 TOC regression (bug 12077)
9983 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
9985 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
9987 <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>
9990 <li class="toclevel-1 tocsection-3"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a></li>
9993 <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>
9994 <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>
9995 <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>
10000 BUG 1219 URL next to image (good)
10002 http://example.com [[Image:foobar.jpg]]
10004 <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>
10009 Short headings with trailing space should match behavior of Parser::doHeadings (bug 19910)
10012 The line above must have a trailing space!
10015 But just in case it doesn't...
10017 <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>
10018 <p>The line above must have a trailing space!
10020 <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>
10021 <p>But just in case it doesn't...
10026 Header with special characters (bug 25462)
10028 The tooltips shall not show entities to the user (ie. be double escaped)
10045 <p>The tooltips shall not show entities to the user (ie. be double escaped)
10047 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
10049 <li class="toclevel-1 tocsection-1"><a href="#text_.3E_text"><span class="tocnumber">1</span> <span class="toctext">text > text</span></a></li>
10050 <li class="toclevel-1 tocsection-2"><a href="#text_.3C_text"><span class="tocnumber">2</span> <span class="toctext">text < text</span></a></li>
10051 <li class="toclevel-1 tocsection-3"><a href="#text_.26_text"><span class="tocnumber">3</span> <span class="toctext">text & text</span></a></li>
10052 <li class="toclevel-1 tocsection-4"><a href="#text_.27_text"><span class="tocnumber">4</span> <span class="toctext">text ' text</span></a></li>
10053 <li class="toclevel-1 tocsection-5"><a href="#text_.22_text"><span class="tocnumber">5</span> <span class="toctext">text " text</span></a></li>
10056 <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>
10059 <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>
10062 <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>
10065 <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>
10068 <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>
10074 Headers with excess '=' characters
10075 (Are similar tests necessary beyond the 1st level?)
10079 =''italic'' heading==
10080 ==''italic'' heading=
10082 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
10084 <li class="toclevel-1 tocsection-1"><a href="#foo.3D"><span class="tocnumber">1</span> <span class="toctext">foo=</span></a></li>
10085 <li class="toclevel-1 tocsection-2"><a href="#.3Dfoo"><span class="tocnumber">2</span> <span class="toctext">=foo</span></a></li>
10086 <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>
10087 <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>
10090 <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>
10091 <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>
10092 <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>
10093 <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>
10098 HTML headers vs TOC (bug 23393)
10099 (__NOEDITSECTION__ for clearer output, doesn't matter here)
10111 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
10113 <li class="toclevel-1"><a href="#Header_1"><span class="tocnumber">1</span> <span class="toctext">Header 1</span></a>
10115 <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>
10116 <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>
10119 <li class="toclevel-1"><a href="#Header_2"><span class="tocnumber">2</span> <span class="toctext">Header 2</span></a>
10121 <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>
10122 <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>
10127 <h1><span class="mw-headline" id="Header_1">Header 1</span></h1>
10128 <h2><span class="mw-headline" id="Header_1.1">Header 1.1</span></h2>
10129 <h2><span class="mw-headline" id="Header_1.2">Header 1.2</span></h2>
10130 <h1><span class="mw-headline" id="Header_2">Header 2</span></h1>
10131 <h2><span class="mw-headline" id="Header_2.1">Header 2.1</span></h2>
10132 <h2><span class="mw-headline" id="Header_2.2">Header 2.2</span></h2>
10137 BUG 1219 URL next to image (broken)
10139 http://example.com[[Image:foobar.jpg]]
10141 <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>
10146 Bug 1186 news: in the middle of text
10148 http://en.wikinews.org/wiki/Wikinews:Workplace
10150 <p><a rel="nofollow" class="external free" href="http://en.wikinews.org/wiki/Wikinews:Workplace">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
10156 Namespaced link must have a title
10165 Namespaced link must have a title (bad fragment version)
10167 [[Project:#fragment]]
10169 <p>[[Project:#fragment]]
10175 ### HTML tags and HTML attributes
10179 div with no attributes
10181 <div>HTML rocks</div>
10183 <div>HTML rocks</div>
10188 div with double-quoted attribute
10190 <div id="rock">HTML rocks</div>
10192 <div id="rock">HTML rocks</div>
10197 div with single-quoted attribute
10199 <div id='rock'>HTML rocks</div>
10201 <div id="rock">HTML rocks</div>
10206 div with unquoted attribute
10208 <div id=rock>HTML rocks</div>
10210 <div id="rock">HTML rocks</div>
10215 div with illegal double attributes
10217 <div id="a" id="b">HTML rocks</div>
10219 <div id="b">HTML rocks</div>
10223 # FIXME: produce empty string instead of "class" in the PHP parser, following
10226 div with empty attribute value, space before equals
10230 <div class =>HTML rocks</div>
10232 <div class="">HTML rocks</div>
10236 # The PHP parser escapes the opening brace to { for some reason, so
10237 # disabled this test for it.
10239 div with braces in attribute value
10243 <div title="{}">Foo</div>
10245 <div title="{}">Foo</div>
10248 # This it very inconsistent in the PHP parser: it returns
10249 # class="class" if there is a space between the name and the equal sign (see
10250 # 'div with empty attribute value, space before equals'), but strips the
10251 # attribute completely if the space is missing. We hope that not much content
10252 # depends on this, so are implementing the behavior below in Parsoid for
10253 # consistencies' sake. Disabled for the PHP parser.
10254 # FIXME: fix this behavior in the PHP parser?
10256 div with empty attribute value, no space before equals
10260 <div class=>HTML rocks</div>
10262 <div class="">HTML rocks</div>
10267 HTML multiple attributes correction
10269 <p class="error" class="awesome">Awesome!</p>
10271 <p class="awesome">Awesome!</p>
10276 Table multiple attributes correction
10279 !+ class="error" class="awesome"| status
10284 <th class="awesome"> status
10292 <DIV ID="x">HTML ROCKS</DIV>
10294 <div id="x">HTML ROCKS</div>
10299 Non-ASCII pseudo-tags are rendered as text
10308 Pseudo-tag with URL 'name' renders as url link
10310 <http://example.com/>
10312 <p><<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>>
10317 text with amp in the middle of nowhere
10321 <p>Remember AT&T?
10326 text with character entity: eacute
10328 I always thought é was a cute letter.
10330 <p>I always thought é was a cute letter.
10335 text with entity-escaped character entity-like string: eacute
10337 I always thought &eacute; was a cute letter.
10339 <p>I always thought &eacute; was a cute letter.
10344 text with undefined character entity: xacute
10346 I always thought &xacute; was a cute letter.
10348 <p>I always thought &xacute; was a cute letter.
10354 ### Nesting tests (see bug 41545, 50604, 51081)
10357 # This test case is fixed in Parsoid by domino 1.0.12. (bug 50604)
10358 # Note that html2wt is considerably more difficult if we use <b> in
10359 # the test case, instead of <big>
10361 Ensure that HTML adoption agency algorithm is properly implemented.
10363 <big>X<big>Y</big>Z</big>
10365 <p><big>X<big>Y</big>Z</big>
10369 # This was bug 41545 in the PHP parser.
10373 <kbd>X<kbd>Y</kbd>Z</kbd>
10375 <p><kbd>X<kbd>Y</kbd>Z</kbd>
10379 # The following cases were bug 51081 in the PHP parser.
10380 # Note that there are some other nestable tags (b, i, etc) which are
10381 # not covered; see bug 51081 for discussion.
10385 <em>X<em>Y</em>Z</em>
10387 <p><em>X<em>Y</em>Z</em>
10392 Nesting of <strong>
10394 <strong>X<strong>Y</strong>Z</strong>
10396 <p><strong>X<strong>Y</strong>Z</strong>
10405 <p><q>X<q>Y</q>Z</q>
10412 <ruby>X<ruby>Y</ruby>Z</ruby>
10414 <p><ruby>X<ruby>Y</ruby>Z</ruby>
10421 <bdo>X<bdo>Y</bdo>Z</bdo>
10423 <p><bdo>X<bdo>Y</bdo>Z</bdo>
10435 [[Media:Foobar.jpg]]
10437 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Media:Foobar.jpg</a>
10442 Media link with text
10444 [[Media:Foobar.jpg|A neat file to look at]]
10446 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">A neat file to look at</a>
10450 # FIXME: this is still bad HTML tag nesting
10452 Media link with nasty text
10453 fixme: doBlockLevels won't wrap this in a paragraph because it contains a div
10455 [[Media:Foobar.jpg|Safe Link<div style=display:none>" onmouseover="alert(document.cookie)" onfoo="</div>]]
10457 <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>
10462 Media link to nonexistent file (bug 1702)
10464 [[Media:No such.jpg]]
10466 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="No such.jpg">Media:No such.jpg</a>
10471 Image link to nonexistent file (bug 1850 - good)
10473 [[Image:No such.jpg]]
10475 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="File:No such.jpg">File:No such.jpg</a>
10480 :Image link to nonexistent file (bug 1850 - bad)
10482 [[:Image:No such.jpg]]
10484 <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>
10491 Character reference normalization in link text (bug 1938)
10493 [[Main Page|this&that]]
10495 <p><a href="/wiki/Main_Page" title="Main Page">this&that</a>
10502 Test for unicode normalization
10504 The page's name is U+05d0 U+05b7, with non-canonical form U+FB2E
10508 (bug 19451) Links should refer to the normalized form.
10516 <p><a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
10517 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
10518 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
10519 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
10520 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
10525 Empty attribute crash test (bug 2067)
10527 <font color="">foo</font>
10529 <p><font color="">foo</font>
10534 Empty attribute crash test single-quotes (bug 2067)
10536 <font color=''>foo</font>
10538 <p><font color="">foo</font>
10543 Attribute test: equals, then nothing
10545 <font color=>foo</font>
10547 <p><font>foo</font>
10552 Attribute test: unquoted value
10554 <font color=x>foo</font>
10556 <p><font color="x">foo</font>
10561 Attribute test: unquoted but illegal value (hash)
10563 <font color=#x>foo</font>
10565 <p><font color="#x">foo</font>
10570 Attribute test: no value
10572 <font color>foo</font>
10574 <p><font color="color">foo</font>
10579 Bug 2095: link with three closing brackets
10583 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>]
10588 Bug 2095: link with pipe and three closing brackets
10590 [[Main Page|link]]]
10592 <p><a href="/wiki/Main_Page" title="Main Page">link</a>]
10597 Bug 2095: link with pipe and three closing brackets, version 2
10599 [[Main Page|[http://example.com/]]]
10601 <p><a href="/wiki/Main_Page" title="Main Page">[http://example.com/]</a>
10611 Template:Dangerous attribute
10613 " onmouseover="alert(document.cookie)
10617 Template:Dangerous style attribute
10619 border-size: expression(alert(document.cookie))
10625 <div style="float: right; {{{1}}}">Magic div</div>
10629 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
10631 <div title="{{test}}"></div>
10633 <div title="This is a test template"></div>
10638 Bug 2304: HTML attribute safety (dangerous template; 2309)
10640 <div title="{{dangerous attribute}}"></div>
10642 <div title=""></div>
10647 Bug 2304: HTML attribute safety (dangerous style template; 2309)
10649 <div style="{{dangerous style attribute}}"></div>
10651 <div style="/* insecure input */"></div>
10656 Bug 2304: HTML attribute safety (safe parameter; 2309)
10658 {{div style|width: 200px}}
10660 <div style="float: right; width: 200px">Magic div</div>
10665 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
10667 {{div style|width: expression(alert(document.cookie))}}
10669 <div style="/* insecure input */">Magic div</div>
10674 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
10676 {{div style|"><script>alert(document.cookie)</script>}}
10678 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
10683 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
10685 {{div style|" ><script>alert(document.cookie)</script>}}
10687 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
10692 Bug 2304: HTML attribute safety (link)
10694 <div title="[[Main Page]]"></div>
10696 <div title="[[Main Page]]"></div>
10701 Bug 2304: HTML attribute safety (italics)
10703 <div title="''foobar''"></div>
10705 <div title="''foobar''"></div>
10710 Bug 2304: HTML attribute safety (bold)
10712 <div title="'''foobar'''"></div>
10714 <div title="'''foobar'''"></div>
10720 Bug 2304: HTML attribute safety (ISBN)
10722 <div title="ISBN 1234567890"></div>
10724 <div title="ISBN 1234567890"></div>
10729 Bug 2304: HTML attribute safety (RFC)
10731 <div title="RFC 1234"></div>
10733 <div title="RFC 1234"></div>
10738 Bug 2304: HTML attribute safety (PMID)
10740 <div title="PMID 1234567890"></div>
10742 <div title="PMID 1234567890"></div>
10747 Bug 2304: HTML attribute safety (web link)
10749 <div title="http://example.com/"></div>
10751 <div title="http://example.com/"></div>
10756 Bug 2304: HTML attribute safety (named web link)
10758 <div title="[http://example.com/ link]"></div>
10760 <div title="[http://example.com/ link]"></div>
10765 Bug 3244: HTML attribute safety (extension; safe)
10767 <div style="<nowiki>background:blue</nowiki>"></div>
10769 <div style="background:blue"></div>
10774 Bug 3244: HTML attribute safety (extension; unsafe)
10776 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
10778 <div style="/* insecure input */"></div>
10782 # More MSIE fun discovered by Tom Gilder
10785 MSIE CSS safety test: spurious slash
10787 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
10789 <div style="/* insecure input */">evil</div>
10794 MSIE CSS safety test: hex code
10796 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
10798 <div style="/* insecure input */">evil</div>
10803 MSIE CSS safety test: comment in url
10805 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
10807 <div style="background-image:u rl(javascript:alert('boo'))">evil</div>
10812 MSIE CSS safety test: comment in expression
10814 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
10816 <div style="background-image:expres sion(alert('boo4'))">evil4</div>
10822 Table attribute legitimate extension
10825 !+ style="<nowiki>color:blue</nowiki>"| status
10830 <th style="color:blue"> status
10836 Table attribute safety
10839 !+ style="<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>"| status
10844 <th style="/* insecure input */"> status
10850 CSS line continuation 1
10852 <div style="background-image: u\ rl(test.jpg);"></div>
10854 <div style="/* insecure input */"></div>
10859 CSS line continuation 2
10861 <div style="background-image: u\ rl(test.jpg); "></div>
10863 <div style="/* insecure input */"></div>
10874 Expansion of multi-line templates in attribute values (bug 6255)
10876 <div style="background: {{identity|#00FF00}}">-</div>
10878 <div style="background: #00FF00">-</div>
10884 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
10886 <div style="background:
10889 <div style="background: #00FF00">-</div>
10894 Expansion of multi-line templates in attribute values (bug 6255 sanity check 2)
10896 <div style="background: #00FF00">-</div>
10898 <div style="background: #00FF00">-</div>
10903 ### Parser hooks (see tests/parser/parserTestsParserHook.php for the <tag> extension)
10906 Parser hook: empty input
10919 Parser hook: empty input using terminated empty elements
10932 Parser hook: empty input using terminated empty elements (space before)
10945 Parser hook: basic input
10959 Parser hook: case insensitive
10973 Parser hook: case insensitive, redux
10986 Parser hook: nested tags
10990 <tag><tag></tag></tag>
11001 Parser hook: basic arguments
11003 <tag width=200 height = "100" depth = '50' square></tag>
11011 'square' => 'square',
11018 Parser hook: argument containing a forward slash (bug 5344)
11020 <tag filename='/tmp/bla'></tag>
11025 'filename' => '/tmp/bla',
11032 Parser hook: empty input using terminated empty elements (bug 2374)
11045 # </tag> should be output literally since there is no matching tag that begins it
11047 Parser hook: basic arguments using terminated empty elements (bug 2374)
11049 <tag width=200 height = "100" depth = '50' square/>
11059 'square' => 'square',
11068 ### (see tests/parser/parserTestsParserHook.php for the <statictag> extension)
11072 Parser hook: static parser hook not inside a comment
11074 <statictag>hello, world</statictag>
11075 <statictag action=flush/>
11083 Parser hook: static parser hook inside a comment
11085 <!-- <statictag>hello, world</statictag> -->
11086 <statictag action=flush/>
11092 # Nested template calls; this case was broken by Parser.php rev 1.506,
11096 Template:One-parameter
11098 (My parameter is: {{{1}}})
11102 Template:Map-one-parameter
11104 {{{{{1}}}|{{{2}}}}}
11108 Nested template calls
11110 {{Map-one-parameter|One-parameter|param}}
11112 <p>(My parameter is: param)
11121 Sanitizer: Closing of open tags
11123 <s></s><table></table>
11125 <s></s><table></table>
11130 Sanitizer: Closing of open but not closed tags
11139 Sanitizer: Closing of closed but not open tags
11148 Sanitizer: Closing of closed but not open table tags
11150 Table not started</td></tr></table>
11152 <p>Table not started</td></tr></table>
11157 Sanitizer: Escaping of spaces, multibyte characters, colons & other stuff in id=""
11159 <span id="æ: v">byte</span>[[#æ: v|backlink]]
11161 <p><span id=".C3.A6:_v">byte</span><a href="#.C3.A6:_v">backlink</a>
11166 Sanitizer: Validating the contents of the id attribute (bug 4515)
11172 Something, but definitely not <br id="9" />...
11176 Sanitizer: Validating id attribute uniqueness (bug 4515, bug 6301)
11180 <br id="foo" /><br id="foo" />
11182 Something need to be done. foo-2 ?
11186 Sanitizer: Validating that <meta> and <link> work, but only for Microdata
11189 <meta itemprop="hello" content="world">
11190 <meta http-equiv="refresh" content="5">
11191 <meta itemprop="hello" http-equiv="refresh" content="5">
11192 <link itemprop="hello" href="{{SERVER}}">
11193 <link rel="stylesheet" href="{{SERVER}}">
11194 <link rel="stylesheet" itemprop="hello" href="{{SERVER}}">
11197 <div itemscope="itemscope">
11198 <p> <meta itemprop="hello" content="world" />
11199 <meta http-equiv="refresh" content="5">
11200 <meta itemprop="hello" content="5" />
11202 <link itemprop="hello" href="http://example.org" />
11203 <link rel="stylesheet" href="<a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>">
11204 <link itemprop="hello" href="http://example.org" />
11210 Language converter: output gets cut off unexpectedly (bug 5757)
11214 this bit is safe: }-
11216 but if we add a conversion instance: -{zh-cn:xxx;zh-tw:yyy}-
11218 then we get cut off here: }-
11220 all additional text is vanished
11222 <p>this bit is safe: }-
11223 </p><p>but if we add a conversion instance: xxx
11224 </p><p>then we get cut off here: }-
11225 </p><p>all additional text is vanished
11230 Self closed html pairs (bug 5487)
11233 <center><font id="bug" />Centered text</center>
11234 <div><font id="bug2" />In div text</div>
11236 <center><font id="bug" />Centered text</center>
11237 <div><font id="bug2" />In div text</div>
11246 Punctuation: nbsp before exclamation
11250 <p>C'est grave !
11255 Punctuation: CSS !important (bug 11874)
11257 <div style="width:50% !important">important</div>
11259 <div style="width:50% !important">important</div>
11264 Punctuation: CSS ! important (bug 11874; with space after)
11266 <div style="width:50% ! important">important</div>
11268 <div style="width:50% ! important">important</div>
11274 HTML bullet list, closed tags (bug 5497)
11289 HTML bullet list, unclosed tags (bug 5497)
11306 HTML ordered list, closed tags (bug 5497)
11321 HTML ordered list, unclosed tags (bug 5497)
11338 HTML nested bullet list, closed tags (bug 5497)
11363 HTML nested bullet list, open tags (bug 5497)
11388 HTML nested ordered list, closed tags (bug 5497)
11413 HTML nested ordered list, open tags (bug 5497)
11438 HTML ordered list item with parameters oddity
11440 <ol><li id="fragment">One</li></ol>
11442 <ol><li id="fragment">One</li></ol>
11447 bug 5918: autonumbering
11449 [http://first/] [http://second] [ftp://ftp]
11453 [mailto:enclosed@mail.tld With target]
11455 [mailto:enclosed@mail.tld]
11457 mailto:inline@mail.tld
11459 <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>
11460 </p><p><a rel="nofollow" class="external free" href="ftp://inlineftp">ftp://inlineftp</a>
11461 </p><p><a rel="nofollow" class="external text" href="mailto:enclosed@mail.tld">With target</a>
11462 </p><p><a rel="nofollow" class="external autonumber" href="mailto:enclosed@mail.tld">[4]</a>
11463 </p><p><a rel="nofollow" class="external free" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a>
11469 # Security and HTML correctness
11470 # From Nick Jenkins' fuzz testing
11474 Fuzz testing: Parser13
11489 Fuzz testing: Parser14
11494 <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>
11495 http://<div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
11497 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
11504 Fuzz testing: Parser14-table
11509 <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>
11510 <table style="__TOC__">
11516 # Known to produce bogus xml (extra </td>)
11518 Fuzz testing: Parser16
11538 Fuzz testing: Parser21
11541 ! irc://{{ftp://a" onmouseover="alert('hello world');"
11546 <th> <a rel="nofollow" class="external free" href="irc://{{ftp://a">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
11556 Fuzz testing: Parser22
11558 http://===r:::https://b
11562 <p><a rel="nofollow" class="external free" href="http://===r:::https://b">http://===r:::https://b</a>
11570 # Known to produce bad XML for now
11572 Fuzz testing: Parser24
11579 | {{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}} >
11580 <br style="onmouseover='alert(document.cookie);' " />
11582 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
11587 <u class="|">}}}} >
11588 <br style="onmouseover='alert(document.cookie);'" />
11590 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
11599 # Note: the current result listed for this is not what the original one was,
11600 # but the original bug was JavaScript injection, which is fixed in any case.
11601 # It's not clear that the original result listed was any more correct than the
11602 # current one. Original result:
11605 # <li class="||">
11606 # }}}blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
11608 Fuzz testing: Parser25 (bug 6055)
11614 }}}blah" onmouseover="alert('hello world');" align="left"'''MOVE MOUSE CURSOR OVER HERE
11616 <p><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
11621 Fuzz testing: URL adjacent extension (with space, clean)
11624 http://example.com <nowiki>junk</nowiki>
11626 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> junk
11631 Fuzz testing: URL adjacent extension (no space, dirty; nowiki)
11634 http://example.com<nowiki>junk</nowiki>
11636 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>junk
11641 Fuzz testing: URL adjacent extension (no space, dirty; pre)
11644 http://example.com<pre>junk</pre>
11646 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><pre>junk</pre>
11651 Fuzz testing: image with bogus manual thumbnail
11653 [[Image:foobar.jpg|thumbnail= ]]
11655 <div class="thumb tright"><div class="thumbinner" style="width:182px;">Error creating thumbnail: <div class="thumbcaption"></div></div></div>
11660 Fuzz testing: encoded newline in generated HTML replacements (bug 6577)
11662 <pre dir=" "></pre>
11664 <pre dir=" "></pre>
11669 Parsing optional HTML elements (Bug 6171)
11674 <td> Some tabular data</td>
11675 <td> More tabular data ...
11676 <td> And yet som tabular data</td>
11682 <td> Some tabular data</td>
11683 <td> More tabular data ...
11684 </td><td> And yet som tabular data</td>
11691 Correct handling of <td>, <tr> (Bug 6171)
11696 <td> Some tabular data</td>
11697 <td> More tabular data ...</td>
11698 <td> And yet som tabular data</td>
11704 <td> Some tabular data</td>
11705 <td> More tabular data ...</td>
11706 <td> And yet som tabular data</td>
11714 Parsing crashing regression (fr:JavaScript)
11718 <p></body></x>
11723 Inline wiki vs wiki block nesting
11729 <p><b>Bold paragraph</b>
11730 </p><p>New wiki paragraph
11735 Inline HTML vs wiki block nesting
11743 <p><b>Bold paragraph</b>
11744 </p><p>New wiki paragraph
11748 # Original result was this:
11749 # <p><b>bold</b><b>bold<i>bolditalics</i></b>
11751 # While that might be marginally more intuitive, maybe, the six-apostrophe
11752 # construct is clearly pathological and the result stated here (which is what
11753 # the parser actually does) is about as reasonable as anything.
11755 Mixing markup for italics and bold
11758 '''bold''''''bold''bolditalics'''''
11760 <p>'<i>bold'</i><b>bold<i>bolditalics</i></b>
11768 Article for special page transclusion test
11772 Special page transclusion
11775 {{Special:Prefixindex/Xyzzyx}}
11777 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
11782 Special page transclusion twice (bug 5021)
11785 {{Special:Prefixindex/Xyzzyx}}
11786 {{Special:Prefixindex/Xyzzyx}}
11788 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
11789 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
11794 Transclusion of default MediaWiki message
11796 {{MediaWiki:Mainpage}}
11803 Transclusion of nonexistent MediaWiki message
11805 {{MediaWiki:Mainpagexxx}}
11807 <p><a href="/index.php?title=MediaWiki:Mainpagexxx&action=edit&redlink=1" class="new" title="MediaWiki:Mainpagexxx (page does not exist)">MediaWiki:Mainpagexxx</a>
11812 Transclusion of MediaWiki message with underscore
11814 {{MediaWiki:history_short}}
11821 Transclusion of MediaWiki message with space
11823 {{MediaWiki:history short}}
11830 Invalid header with following text
11840 Section extraction test (section 0)
11860 Section extraction test (section 1)
11882 Section extraction test (section 2)
11903 Section extraction test (section 3)
11923 Section extraction test (section 4)
11947 Section extraction test (section 5)
11967 Section extraction test (section 6)
11988 Section extraction test (section 7)
12008 Section extraction test (section 8)
12028 Section extraction test (section 9)
12049 Section extraction test (section 10)
12069 Section extraction test (nonexistent section 11)
12088 Section extraction test with bogus heading (section 1)
12093 ==bogus== not a legal section
12097 ==bogus== not a legal section
12101 Section extraction test with bogus heading (section 2)
12106 ==bogus== not a legal section
12113 Section extraction test with comment after heading (section 1)
12125 Section extraction test with comment after heading (section 2)
12137 Section extraction test with bogus <nowiki> heading (section 1)
12142 ==bogus== <nowiki>not a legal section</nowiki>
12146 ==bogus== <nowiki>not a legal section</nowiki>
12150 Section extraction test with bogus <nowiki> heading (section 2)
12155 ==bogus== <nowiki>not a legal section</nowiki>
12162 # Formerly testing for bug 2587, now resolved by the use of unmarked sections
12163 # instead of respecting commented sections
12165 Section extraction prefixed by comment (section 1)
12176 Section extraction prefixed by comment (section 2)
12187 # Formerly testing for bug 2607, now resolved by the use of unmarked sections
12188 # instead of respecting HTML-style headings
12190 Section extraction, mixed wiki and html (section 1)
12206 Section extraction, mixed wiki and html (section 2)
12222 # Formerly testing for bug 3342
12224 Section extraction, heading surrounded by <noinclude>
12228 <noinclude>==unmarked==</noinclude>
12234 # Test behavior of bug 19910
12236 Sectiion with all-equals
12241 The line above must have a trailing space
12244 But just in case it doesn't...
12248 But just in case it doesn't...
12252 Section replacement test (section 0)
12283 Section replacement test (section 1)
12312 Section replacement test (section 2)
12342 Section replacement test (section 3)
12373 Section replacement test (section 4)
12400 Section replacement test (section 5)
12431 Section replacement test (section 6)
12461 Section replacement test (section 7)
12492 Section replacement test (section 8)
12523 Section replacement test (section 9)
12552 Section replacement test (section 10)
12582 Section replacement test with initial whitespace (bug 13728)
12586 Preformatted initial line
12590 Preformatted initial line
12597 Section extraction, heading followed by pre with 20 spaces (bug 6398)
12609 Section extraction, heading followed by pre with 19 spaces (bug 6398 sanity check)
12622 Section extraction, <pre> around bogus header (bug 10309)
12639 Section replacement, <pre> around bogus header (bug 10309)
12641 noxml replace=2,"xxx"
12662 Handling of 
 in URLs
12666 <ul><li><ul><li><a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a>
12673 5 quotes, code coverage +1 line (php)
12680 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
12682 5 quotes, code coverage +1 line (parsoid)
12688 <p><i><b></b></i></p>
12692 Special:Search page linking.
12696 <p><a href="/wiki/Special:Search" title="Special:Search">Special:Search</a>
12703 title=[[Parser test]]
12708 * {{FULLPAGENAMEE}}
12710 * {{BASEPAGENAMEE}}
12714 * {{ROOTPAGENAMEE}}
12716 * {{TALKPAGENAMEE}}
12717 * {{SUBJECTPAGENAME}}
12718 * {{SUBJECTPAGENAMEE}}
12721 * {{NAMESPACENUMBER}}
12725 * {{SUBJECTSPACEE}}
12726 * {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}
12728 <ul><li> Parser test
12729 </li><li> Parser_test
12730 </li><li> Parser test
12731 </li><li> Parser_test
12732 </li><li> Parser test
12733 </li><li> Parser_test
12734 </li><li> Parser test
12735 </li><li> Parser_test
12736 </li><li> Parser test
12737 </li><li> Parser_test
12738 </li><li> Talk:Parser test
12739 </li><li> Talk:Parser_test
12740 </li><li> Parser test
12741 </li><li> Parser_test
12749 </li><li> <a href="/index.php?title=Template:Dynamic&action=edit&redlink=1" class="new" title="Template:Dynamic (page does not exist)">Template:Dynamic</a>
12753 ### Note: Above tests excludes the "{{NUMBEROFADMINS}}" magic word because it generates a MySQL error when included.
12763 image4 |300px| centre
12764 image5.svg| http://///////
12769 <ul class="gallery">
12770 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12771 <div style="height: 150px;">Image1.png</div>
12772 <div class="gallerytext">
12775 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12776 <div style="height: 150px;">Image2.gif</div>
12777 <div class="gallerytext">
12782 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12783 <div style="height: 150px;">Image3</div>
12784 <div class="gallerytext">
12787 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12788 <div style="height: 150px;">Image4</div>
12789 <div class="gallerytext">
12794 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12795 <div style="height: 150px;">Image5.svg</div>
12796 <div class="gallerytext">
12797 <p><a rel="nofollow" class="external free" href="http://///////">http://///////</a>
12801 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12802 <div style="height: 150px;">* image6</div>
12803 <div class="gallerytext">
12811 Gallery (with options)
12813 <gallery widths='70px' heights='40px' perrow='2' caption='Foo [[Main Page]]' >
12814 File:Nonexistant.jpg|caption
12815 File:Nonexistant.jpg
12816 image:foobar.jpg|some '''caption''' [[Main Page]]
12818 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
12821 <ul class="gallery" style="max-width: 226px;_width: 226px;">
12822 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
12823 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12824 <div style="height: 70px;">Nonexistant.jpg</div>
12825 <div class="gallerytext">
12830 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12831 <div style="height: 70px;">Nonexistant.jpg</div>
12832 <div class="gallerytext">
12835 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12836 <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>
12837 <div class="gallerytext">
12838 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
12842 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12843 <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>
12844 <div class="gallerytext">
12847 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
12848 <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>
12849 <div class="gallerytext">
12859 Gallery with wikitext inside caption
12862 File:foobar.jpg|[[File:foobar.jpg|20px|desc|alt=inneralt]]|alt=galleryalt
12863 File:foobar.jpg|{{Test|unamedParam|alt=param}}|alt=galleryalt
12866 <ul class="gallery">
12867 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12868 <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>
12869 <div class="gallerytext">
12870 <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>
12874 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12875 <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>
12876 <div class="gallerytext">
12877 <p>This is a test template
12886 gallery (with showfilename option)
12888 <gallery showfilename>
12889 File:Nonexistant.jpg|caption
12890 File:Nonexistant.jpg
12891 image:foobar.jpg|some '''caption''' [[Main Page]]
12895 <ul class="gallery">
12896 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12897 <div style="height: 150px;">Nonexistant.jpg</div>
12898 <div class="gallerytext">
12899 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
12904 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12905 <div style="height: 150px;">Nonexistant.jpg</div>
12906 <div class="gallerytext">
12907 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
12911 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12912 <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>
12913 <div class="gallerytext">
12914 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
12915 some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
12919 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12920 <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>
12921 <div class="gallerytext">
12922 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
12931 Gallery (with namespace-less filenames)
12934 File:Nonexistant.jpg
12940 <ul class="gallery">
12941 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12942 <div style="height: 150px;">Nonexistant.jpg</div>
12943 <div class="gallerytext">
12946 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12947 <div style="height: 150px;">Nonexistant.jpg</div>
12948 <div class="gallerytext">
12951 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12952 <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>
12953 <div class="gallerytext">
12956 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12957 <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>
12958 <div class="gallerytext">
12966 HTML Hex character encoding (spells the word "JavaScript")
12968 JavaScript
12970 <p>JavaScript
12975 HTML Hex character encoding bogus encoding (bug 26437 regression check)
12979 <p>&#xsee;&#XSEE;
12984 HTML Hex character encoding mixed case
12993 __FORCETOC__ override
13005 ISBN 978-0-1234-56 789
13007 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789
13012 ISBN followed by 5 spaces
13023 ISBN ISBN 1234567890
13025 <p>ISBN <a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
13030 Bug 22905: <abbr> followed by ISBN followed by </a>
13032 <abbr>(fr)</abbr> ISBN 2753300917 [http://www.example.com example.com]
13034 <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>
13043 <p>RFC <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a>
13048 Double RFC with a wiki link
13052 <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>
13061 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987
13066 Centre-aligned image
13068 [[Image:foobar.jpg|centre]]
13070 <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>
13077 [[Image:foobar.jpg|none]]
13079 <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>
13084 Width + Height sized image (using px) (height is ignored)
13086 [[Image:foobar.jpg|640x480px]]
13088 <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>
13093 Width-sized image (using px, no following whitespace)
13095 [[Image:foobar.jpg|640px]]
13097 <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>
13102 Width-sized image (using px, with following whitespace - test regression from r39467)
13104 [[Image:foobar.jpg|640px ]]
13106 <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>
13111 Width-sized image (using px, with preceding whitespace - test regression from r39467)
13113 [[Image:foobar.jpg| 640px]]
13115 <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>
13120 Another italics / bold test
13128 # Note the results may be incorrect, as parserTest output included this:
13129 # XML error: Mismatched tag at byte 6120:
13130 # ...<dd> </dt></dl> </dd...
13138 <dl><dd><dl><dt><dl><dt><dl><dt><dl><dd><dl><dd>
13149 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
13151 Images with the "|" character in the comment
13153 [[image:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]]
13155 <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>
13160 [Before] HTML without raw HTML enabled ($wgRawHtml==false)
13162 <html><script>alert(1);</script></html>
13164 <p><html><script>alert(1);</script></html>
13169 HTML with raw HTML ($wgRawHtml==true)
13173 <html><script>alert(1);</script></html>
13175 <p><script>alert(1);</script>
13180 Parents of subpages, one level up
13182 subpage title=[[Subpage test/L1/L2/L3]]
13186 <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>
13192 Parents of subpages, one level up, not named
13194 subpage title=[[Subpage test/L1/L2/L3]]
13198 <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>
13205 Parents of subpages, two levels up
13207 subpage title=[[Subpage test/L1/L2/L3]]
13213 <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
13214 </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>
13219 Parents of subpages, two levels up, without trailing slash or name.
13221 subpage title=[[Subpage test/L1/L2/L3]]
13230 Parents of subpages, two levels up, with lots of extra trailing slashes.
13232 subpage title=[[Subpage test/L1/L2/L3]]
13236 <p><a href="/index.php?title=Subpage_test/L1////&action=edit&redlink=1" class="new" title="Subpage test/L1//// (page does not exist)">///</a>
13241 Subpage test/L1/L2/L3Sibling
13247 Transclusion of a sibling page (one level up)
13249 subpage title=[[Subpage test/L1/L2/L3]]
13258 Transclusion of a child page
13260 subpage title=[[Subpage test/L1/L2]]
13269 Non-transclusion because of too many up levels
13271 subpage title=[[Subpage test/L1/L2/L3]]
13273 {{../../../../More than parent}}
13275 <p>{{../../../../More than parent}}
13280 Definition list code coverage
13286 <dl><dt> title  </dt><dd> def
13287 </dd><dt> title </dt><dd> def
13288 </dd><dt>title</dt><dd> def
13294 Don't fall for the self-closing div
13296 <div>hello world</div/>
13298 <div>hello world</div>
13307 <p>[[:Template:Msg]]
13316 <p><a href="/index.php?title=Template:QUERTY&action=edit&redlink=1" class="new" title="Template:QUERTY (page does not exist)">Template:QUERTY</a>
13320 # This isn't needed for XHTML conformance, but would be handy as a fallback security measure
13322 Always escape literal '>' in output, not just after '<'
13336 <p>This is a test template
13337 This is a test template
13349 Inclusion of !userCanEdit() content
13353 <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>
13359 Out-of-order TOC heading levels
13368 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
13370 <li class="toclevel-1 tocsection-1"><a href="#2"><span class="tocnumber">1</span> <span class="toctext">2</span></a>
13372 <li class="toclevel-2 tocsection-2"><a href="#6"><span class="tocnumber">1.1</span> <span class="toctext">6</span></a></li>
13373 <li class="toclevel-2 tocsection-3"><a href="#3"><span class="tocnumber">1.2</span> <span class="toctext">3</span></a></li>
13376 <li class="toclevel-1 tocsection-4"><a href="#1"><span class="tocnumber">2</span> <span class="toctext">1</span></a>
13378 <li class="toclevel-2 tocsection-5"><a href="#5"><span class="tocnumber">2.1</span> <span class="toctext">5</span></a></li>
13379 <li class="toclevel-2 tocsection-6"><a href="#2_2"><span class="tocnumber">2.2</span> <span class="toctext">2</span></a></li>
13384 <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>
13385 <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>
13386 <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>
13387 <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>
13388 <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>
13389 <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>
13395 ISBN with a dummy number
13405 ISBN with space-delimited number
13409 <p><a href="/wiki/Special:BookSources/9290170328" class="internal mw-magiclink-isbn">ISBN 92 9017 032 8</a>
13415 ISBN with multiple spaces, no number
13434 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
13435 </p><p>ISBN 12345678901
13441 ISBN with trailing year (bug 8110)
13443 ISBN 1-234-56789-0 - 2006
13445 ISBN 1 234 56789 0 - 2006
13447 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1-234-56789-0</a> - 2006
13448 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1 234 56789 0</a> - 2006
13456 {{anchorencode:foo bar©#%n}}
13458 <p>foo_bar.C2.A9.23.25n
13463 anchorencode trims spaces
13465 {{anchorencode: __pretty__please__}}
13472 anchorencode deals with links
13474 {{anchorencode: [[hello|world]] [[hi]]}}
13481 anchorencode deals with templates
13483 {{anchorencode: {{Foo}} }}
13490 anchorencode encodes like the TOC generator: (bug 18431)
13492 === _ +:.3A%3A&&]] ===
13493 {{anchorencode: _ +:.3A%3A&&]] }}
13496 <h3><span class="mw-headline" id=".2B:.3A.253A.26.26.5D.5D">_ +:.3A%3A&&]]</span></h3>
13497 <p>.2B:.3A.253A.26.26.5D.5D
13501 # Expected output in the following test is not necessarily expected (there
13502 # should probably be <p> tags inside the <blockquote> in the output) -- it's
13503 # only testing for well-formedness.
13505 Bug 6200: blockquotes and paragraph formatting
13525 Bug 8293: Use of center tag ruins paragraph formatting
13546 Parsing of overlapping (improperly nested) inline html tags (PHP parser)
13550 <span><s>x</span></s>
13552 <p><span><s>x</span></s></span>
13557 Parsing of overlapping (improperly nested) inline html tags (Parsoid)
13561 <span><s>x</span></s>
13563 <p><span><s>x</s></span><s></s>
13568 ### Language variants related tests
13571 Self-link in language variants
13573 title=[[Dunav]] language=sr
13575 Both [[Dunav]] and [[Дунав]] are names for this river.
13577 <p>Both <strong class="selflink">Dunav</strong> and <strong class="selflink">Дунав</strong> are names for this river.
13588 Link to another existing title shouldn't be parsed as self-link even if it's a variant of this title
13590 title=[[Duna]] language=sr
13592 [[Дуна]] is not a self-link while [[Duna]] and [[Dуна]] are still self-links.
13594 <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.
13599 Link to pages in language variants
13603 Main Page can be written as [[Маин Паге]]
13605 <p>Main Page can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>
13611 Multiple links to pages in language variants
13615 [[Main Page]] can be written as [[Маин Паге]] same as [[Маин Паге]].
13617 <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>.
13623 Simple template in language variants
13629 <p>This is a test template
13635 Template with explicit namespace in language variants
13641 <p>This is a test template
13647 Basic test for template parameter in language variants
13651 {{парамтест|param=foo}}
13653 <p>This is a test template with parameter foo
13659 Simple category in language variants
13663 [[Category:МедиаWики Усер'с Гуиде]]
13665 <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>
13682 Don't convert blue categorylinks to another variant (bug 33210)
13686 [[A]][[Category:分类]]
13688 <a href="/wiki/Category:%E5%88%86%E7%B1%BB" title="Category:分类">分类</a>
13693 Stripping -{}- tags (language variants)
13697 Latin proverb: -{Ne nuntium necare}-
13699 <p>Latin proverb: Ne nuntium necare
13705 Prevent conversion with -{}- tags (language variants)
13707 language=sr variant=sr-ec
13709 Latinski: -{Ne nuntium necare}-
13711 <p>Латински: Ne nuntium necare
13717 Prevent conversion of text with -{}- tags (language variants)
13719 language=sr variant=sr-ec
13721 Latinski: -{Ne nuntium necare}-
13723 <p>Латински: Ne nuntium necare
13729 Prevent conversion of links with -{}- tags (language variants)
13731 language=sr variant=sr-ec
13735 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
13741 -{}- tags within headlines (within html for parserConvert())
13743 language=sr variant=sr-ec
13747 <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>
13753 Explicit definition of language variant alternatives
13755 language=zh variant=zh-tw
13757 -{zh:China;zh-tw:Taiwan}-, not China
13759 <p>Taiwan, not China
13765 Conversion around HTML tags
13767 language=sr variant=sr-ec
13769 -{H|span=>sr-ec:script;title=>sr-ec:src;}-
13770 <span title="La-{sr-el:L;sr-ec:C;}-tin">ski</span>
13773 <span title="ЛаCтин">ски</span>
13779 Explicit session-wise language variant mapping (A flag and - flag)
13781 language=zh variant=zh-tw
13783 Taiwan is not China.
13784 But -{A|zh:China;zh-tw:Taiwan}- is China,
13785 (This-{-|zh:China;zh-tw:Taiwan}- should be stripped!)
13786 and -{China}- is China.
13788 <p>Taiwan is not China.
13789 But Taiwan is Taiwan,
13790 (This should be stripped!)
13791 and China is China.
13796 Explicit session-wise language variant mapping (H flag for hide)
13798 language=zh variant=zh-tw
13800 (This-{H|zh:China;zh-tw:Taiwan}- should be stripped!)
13803 <p>(This should be stripped!)
13809 Adding explicit conversion rule for title (T flag)
13811 language=zh variant=zh-tw showtitle
13813 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
13816 <p>Should be stripped!
13821 Testing that changing the language variant here in the tests actually works
13823 language=zh variant=zh showtitle
13825 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
13828 <p>Should be stripped!
13833 Recursive conversion of alt and title attrs shouldn't clear converter state
13835 language=zh variant=zh-cn showtitle
13837 -{H|zh-cn:Exclamation;zh-tw:exclamation;}-
13838 Should be stripped-{T|zh-cn:China;zh-tw:Taiwan}-<span title="exclamation">!</span>
13842 Should be stripped<span title="Exclamation">!</span>
13847 Bug 24072: more test on conversion rule for title
13849 language=zh variant=zh-tw showtitle
13851 This should be stripped-{T|zh:China;zh-tw:Taiwan}-!
13852 This won't take interferes with the title rule-{H|zh:Beijing;zh-tw:Taipei}-.
13855 <p>This should be stripped!
13856 This won't take interferes with the title rule.
13861 Partly disable title conversion if variant == main language code
13863 language=zh variant=zh title=[[ZH]] showtitle
13865 -{T|zh-cn:CN;zh-tw:TW}-
13873 Partly disable title conversion if variant == main language code, more
13875 language=zh variant=zh title=[[ZH]] showtitle
13885 Raw output of variant escape tags (R flag)
13887 language=zh variant=zh-tw
13889 Raw: -{R|zh:China;zh-tw:Taiwan}-
13891 <p>Raw: zh:China;zh-tw:Taiwan
13896 Nested using of manual convert syntax
13898 language=zh variant=zh-hk
13900 Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiwan;zh-hk:H-{ong}- K-{}-ong;}-;}-!
13902 <p>Nested: Hello Hong Kong!
13907 Proper conversion of text in external links
13909 language=sr variant=sr-ec
13911 http://www.google.com
13912 gopher://www.google.com
13913 [http://www.google.com http://www.google.com]
13914 [gopher://www.google.com gopher://www.google.com]
13915 [https://www.google.com irc://www.google.com]
13916 [ftp://www.google.com www.google.com/ftp://dir]
13917 [//www.google.com www.google.com]
13919 <p><a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
13920 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
13921 <a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
13922 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
13923 <a rel="nofollow" class="external text" href="https://www.google.com">irc://www.google.com</a>
13924 <a rel="nofollow" class="external text" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
13925 <a rel="nofollow" class="external text" href="//www.google.com">www.гоогле.цом</a>
13930 Do not convert roman numbers to language variants
13932 language=sr variant=sr-ec
13936 <p>Фридрих IV је цар.
13941 Unclosed language converter markup "-{"
13952 Don't convert raw rule "-{R|=>}-" to "=>"
13963 Bug 529: Uncovered bullet
13973 # Plain MediaWiki does not remove empty lists, but tidy actually does.
13974 # Templates in Wikipedia rely on this behavior, as tidy has always been
13975 # enabled there. These tests are normally run *without* tidy, so specify the
13976 # full output here.
13977 # To test realistic parsing behavior, apply a tidy-like transformation to both
13978 # the expected output and your parser's output.
13980 Bug 529: Uncovered bullet leaving empty list, normally removed by tidy
13982 ******* Foo {{bullet}}
13984 <ul><li><ul><li><ul><li><ul><li><ul><li><ul><li><ul><li> Foo
13997 Bug 529: Uncovered table already at line-start
14020 Bug 529: Uncovered bullet in parser function result
14022 * Foo {{lc:{{bullet}} }}
14031 Bug 5678: Double-parsed template argument
14033 {{lc:{{{1}}}|hello}}
14040 Bug 5678: Double-parsed template invocation
14042 {{lc:{{paramtest {{!}} param = hello }} }}
14044 <p>{{paramtest | param = hello }}
14049 Case insensitivity of parser functions for non-ASCII characters (bug 8143)
14052 title=[[Main Page]]
14054 {{PRVNÍVELKÉ:ěščř}}
14055 {{prvnívelké:ěščř}}
14075 Morwen/13: Unclosed link followed by heading
14082 <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>
14087 HHP2.1: Heuristics for headings in preprocessor parenthetical structures
14094 <h1><span class="mw-headline" id="heading">heading</span></h1>
14099 HHP2.2: Heuristics for headings in preprocessor parenthetical structures
14106 <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>
14121 Paragraphs inside divs (no extra line breaks)
14133 Paragraphs inside divs (extra line break on open)
14148 Paragraphs inside divs (extra line break on close)
14163 Paragraphs inside divs (extra line break on open and close)
14180 Nesting tags, paragraphs on lines which begin with <div>
14184 <div></div><strong>A
14193 # Bug 6200: <blockquote> should behave like <div> with respect to line breaks
14195 Bug 6200: paragraphs inside blockquotes (no extra line breaks)
14199 <blockquote>Line one
14201 Line two</blockquote>
14203 <blockquote>Line one
14204 Line two</blockquote>
14209 Bug 6200: paragraphs inside blockquotes (extra line break on open)
14216 Line two</blockquote>
14221 Line two</blockquote>
14226 Bug 6200: paragraphs inside blockquotes (extra line break on close)
14230 <blockquote>Line one
14235 <blockquote>Line one
14243 Bug 6200: paragraphs inside blockquotes (extra line break on open and close)
14262 Paragraphs inside blockquotes/divs (no extra line breaks)
14264 <blockquote><div>Line one
14266 Line two</div></blockquote>
14268 <blockquote><div>Line one
14269 Line two</div></blockquote>
14274 Paragraphs inside blockquotes/divs (extra line break on open)
14279 Line two</div></blockquote>
14284 Line two</div></blockquote>
14289 Paragraphs inside blockquotes/divs (extra line break on close)
14291 <blockquote><div>Line one
14294 </div></blockquote>
14296 <blockquote><div>Line one
14299 </div></blockquote>
14304 Paragraphs inside blockquotes/divs (extra line break on open and close)
14310 </div></blockquote>
14316 </div></blockquote>
14321 Interwiki links trounced by replaceExternalLinks after early LinkHolderArray expansion
14323 wgLinkHolderBatchSize=0
14329 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?1" class="extiw" title="meatball:1">meatball:1</a>
14330 <a href="http://www.usemod.com/cgi-bin/mb.pl?2" class="extiw" title="meatball:2">meatball:2</a>
14331 <a href="http://www.usemod.com/cgi-bin/mb.pl?3" class="extiw" title="meatball:3">meatball:3</a>
14336 Free external link invading image caption
14338 [[Image:Foobar.jpg|thumb|http://x|hello]]
14340 <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>
14345 Bug 15196: localised external link numbers
14349 [http://en.wikipedia.org/]
14351 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/">[۱]</a>
14356 Multibyte character in padleft
14358 {{padleft:-Hello|7|Æ}}
14365 Multibyte character in padright
14367 {{padright:Hello-|7|Æ}}
14374 formatdate parser function
14376 {{#formatdate:2009-03-24}}
14378 <p><span class="mw-formatted-date" title="2009-03-24">2009-03-24</span>
14383 formatdate parser function, with default format
14385 {{#formatdate:2009-03-24|mdy}}
14387 <p><span class="mw-formatted-date" title="2009-03-24">March 24, 2009</span>
14392 Spacing of numbers in formatted dates
14394 {{#formatdate:January 15}}
14396 <p><span class="mw-formatted-date" title="01-15">January 15</span>
14401 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
14403 language=nl title=[[MediaWiki:Common.css]]
14405 {{#formatdate:2009-03-24|dmy}}
14407 <p><span class="mw-formatted-date" title="2009-03-24">24 March 2009</span>
14420 Edit comment with link
14424 I like the [[Main Page]] a lot
14426 I like the <a href="/wiki/Main_Page" title="Main Page">Main Page</a> a lot
14430 Edit comment with link and link text
14434 I like the [[Main Page|best pages]] a lot
14436 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
14440 Edit comment with link and link text with suffix
14444 I like the [[Main Page|best page]]s a lot
14446 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
14450 Edit comment with section link (non-local, eg in history list)
14452 comment title=[[Main Page]]
14454 /* External links */ removed bogus entries
14456 <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
14460 Edit comment with section link and text before it (non-local, eg in history list)
14462 comment title=[[Main Page]]
14464 pre-comment text /* External links */ removed bogus entries
14466 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>
14470 Edit comment with section link (local, eg in diff view)
14472 comment local title=[[Main Page]]
14474 /* External links */ removed bogus entries
14476 <a href="#External_links">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
14480 Edit comment with subpage link (bug 14080)
14484 title=[[Subpage test]]
14486 Poked at a [[/subpage]] here...
14488 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a> here...
14492 Edit comment with subpage link and link text (bug 14080)
14496 title=[[Subpage test]]
14498 Poked at a [[/subpage|neat little page]] here...
14500 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">neat little page</a> here...
14504 Edit comment with bogus subpage link in non-subpage NS (bug 14080)
14507 title=[[Subpage test]]
14509 Poked at a [[/subpage]] here...
14511 Poked at a <a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a> here...
14515 Edit comment with bare anchor link (local, as on diff)
14519 title=[[Main Page]]
14523 <a href="#section">#section</a>
14527 Edit comment with bare anchor link (non-local, as on history)
14530 title=[[Main Page]]
14534 <a href="/wiki/Main_Page#section" title="Main Page">#section</a>
14538 Anchor starting with underscore
14542 <p><a href="#_ref">One</a>
14547 Id starting with underscore
14549 <div id="_ref"></div>
14551 <div id="_ref"></div>
14556 Space normalisation on autocomment (bug 22784)
14559 title=[[Main Page]]
14561 /* __hello__world__ */
14563 <a href="/wiki/Main_Page#hello_world" title="Main Page">→</a><span dir="auto"><span class="autocomment">__hello__world__</span></span>
14567 percent-encoding and + signs in comments (Bug 26410)
14571 [[ABC%33D% ++]] [[ABC%33D% ++|+%20]]
14573 <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>
14577 Bad images - basic functionality
14586 Bad images - bug 16039: text after bad image disappears
14600 Verify that displaytitle works (bug #22501) no displaytitle
14604 wgAllowDisplayTitle=true
14605 wgRestrictDisplayTitle=false
14607 this is not the the title
14610 <p>this is not the the title
14615 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=false
14620 wgAllowDisplayTitle=true
14621 wgRestrictDisplayTitle=false
14623 this is not the the title
14624 {{DISPLAYTITLE:whatever}}
14627 <p>this is not the the title
14632 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true mismatch
14637 wgAllowDisplayTitle=true
14638 wgRestrictDisplayTitle=true
14640 this is not the the title
14641 {{DISPLAYTITLE:whatever}}
14644 <p>this is not the the title
14649 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true matching
14654 wgAllowDisplayTitle=true
14655 wgRestrictDisplayTitle=true
14657 this is not the the title
14658 {{DISPLAYTITLE:screen}}
14661 <p>this is not the the title
14666 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false
14671 wgAllowDisplayTitle=false
14673 this is not the the title
14674 {{DISPLAYTITLE:screen}}
14677 <p>this is not the the title
14678 <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>
14683 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false no DISPLAYTITLE
14688 wgAllowDisplayTitle=false
14690 this is not the the title
14693 <p>this is not the the title
14698 Verify that displaytitle handles inline CSS styles (bug 26547) - rejected value
14703 wgAllowDisplayTitle=true
14704 wgRestrictDisplayTitle=true
14706 this is not the the title
14707 {{DISPLAYTITLE:<span style="display: none;">s</span>creen}}
14709 <span style="/* attempt to bypass $wgRestrictDisplayTitle */">s</span>creen
14710 <p>this is not the the title
14715 Verify that displaytitle handles inline CSS styles (bug 26547) - accepted value
14720 wgAllowDisplayTitle=true
14721 wgRestrictDisplayTitle=true
14723 this is not the the title
14724 {{DISPLAYTITLE:<span style="color: red;">s</span>creen}}
14726 <span style="color: red;">s</span>creen
14727 <p>this is not the the title
14732 preload: check <noinclude> and <includeonly>
14736 Hello <noinclude>cruel</noinclude><includeonly>kind</includeonly> world.
14742 preload: check <onlyinclude>
14746 Goodbye <onlyinclude>Hello world</onlyinclude>
14752 preload: can pass tags through if we want to
14756 <includeonly><</includeonly>includeonly>Hello world<includeonly><</includeonly>/includeonly>
14758 <includeonly>Hello world</includeonly>
14762 preload: check that it doesn't try to do tricks
14766 * <!-- Hello --> ''{{world}}'' {{<includeonly>subst:</includeonly>How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
14768 * <!-- Hello --> ''{{world}}'' {{subst:How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
14772 Play a bit with r67090 and bug 3158
14776 <div style="width:50% !important"> </div>
14777 <div style="width:50% !important"> </div>
14778 <div style="width:50% !important"> </div>
14779 <div style="border : solid;"> </div>
14781 <div style="width:50% !important"> </div>
14782 <div style="width:50% !important"> </div>
14783 <div style="width:50% !important"> </div>
14784 <div style="border : solid;"> </div>
14789 HTML5 data attributes
14791 <span data-foo="bar">Baz</span>
14792 <p data-abc-def_hij="">Quuz</p>
14794 <p><span data-foo="bar">Baz</span>
14796 <p data-abc-def_hij="">Quuz</p>
14801 percent-encoding and + signs in internal links (Bug 26410)
14803 [[User:+%]] [[Page+title%]]
14804 [[%+]] [[%+|%20]] [[%+ ]] [[%+r]]
14805 [[%]] [[+]] [[image:%+abc%39|foo|[[bar]]]]
14806 [[%33%45]] [[%33%45+]]
14808 <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>
14809 <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>
14810 <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>
14811 <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>
14816 Special characters in embedded file links (bug 27679)
14818 [[File:Contains & ampersand.jpg]]
14819 [[File:Does not exist.jpg|Title with & ampersand]]
14821 <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>
14822 <a href="/index.php?title=Special:Upload&wpDestFile=Does_not_exist.jpg" class="new" title="File:Does not exist.jpg">Title with & ampersand</a>
14828 Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)
14830 Text's been normalized?
14832 <p>Text's been normalized?
14837 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate free external links
14839 http://www.example.org/ <-- U+3000 (vim: ^Vu3000)
14841 <p><a rel="nofollow" class="external free" href="http://www.example.org/">http://www.example.org/</a> <-- U+3000 (vim: ^Vu3000)
14846 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links
14848 [http://www.example.org/ ideograms]
14850 <p><a rel="nofollow" class="external text" href="http://www.example.org/">ideograms</a>
14855 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate external images links
14857 http://www.example.org/pic.png <-- U+3000 (vim: ^Vu3000)
14859 <p><img src="http://www.example.org/pic.png" alt="pic.png" /> <-- U+3000 (vim: ^Vu3000)
14883 Bug 31098 Template which includes system messages which includes the template
14887 <p><span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
14888 <span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
14893 Bug31490 Turkish: ucfirst 'blah'
14904 Bug31490 Turkish: ucfirst 'ix'
14915 Bug31490 Turkish: lcfirst 'BLAH'
14926 Bug31490 Turkish: ucfırst (with a dotless i)
14932 <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>
14937 Bug31490 ucfırst (with a dotless i) with English language
14943 <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>
14948 Bug 26375: TOC with italics
14950 title=[[Main Page]]
14953 == ''Lost'' episodes ==
14955 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14957 <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>
14960 <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>
14965 Bug 26375: TOC with bold
14967 title=[[Main Page]]
14970 == '''should be bold''' then normal text ==
14972 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14974 <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>
14977 <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>
14982 Bug 33845: Headings become cursive in TOC when they contain an image
14984 title=[[Main Page]]
14987 == Image [[Image:foobar.jpg]] ==
14989 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
14991 <li class="toclevel-1 tocsection-1"><a href="#Image"><span class="tocnumber">1</span> <span class="toctext">Image</span></a></li>
14994 <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>
14999 Bug 33845 (2): Headings become bold in TOC when they contain a blockquote
15001 title=[[Main Page]]
15004 == <blockquote>Quote</blockquote> ==
15006 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15008 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
15011 <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>
15016 Unclosed tags in TOC
15018 title=[[Main Page]]
15022 <small>Hanc marginis exiguitas non caperet.</small>
15025 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15027 <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>
15030 <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>
15031 <p><small>Hanc marginis exiguitas non caperet.</small>
15037 Multiple tags in TOC
15040 == <i>Foo</i> <b>Bar</b> ==
15042 == <i>Foo</i> <blockquote>Bar</blockquote> ==
15044 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15046 <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>
15047 <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>
15050 <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>
15051 <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>
15056 Tags with parameters in TOC
15059 == <sup class="in-h2">Hello</sup> ==
15061 == <sup class="a > b">Evilbye</sup> ==
15063 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15065 <li class="toclevel-1 tocsection-1"><a href="#Hello"><span class="tocnumber">1</span> <span class="toctext"><sup>Hello</sup></span></a></li>
15066 <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>
15069 <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>
15070 <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>
15075 span tags with directionality in TOC
15078 == <span dir="ltr">C++</span> ==
15080 == <span dir="rtl">זבנג!</span> ==
15082 == <span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span> ==
15084 == <span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span> ==
15086 == <span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span> ==
15088 <div id="toc" class="toc"><div id="toctitle"><h2>Contents</h2></div>
15090 <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>
15091 <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>
15092 <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>
15093 <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>
15094 <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>
15097 <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>
15098 <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>
15099 <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>
15100 <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>
15101 <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>
15108 == {{int:headline_sample}} ==
15112 Bug 32057: Title needed when expanding <h> nodes.
15114 title=[[Main Page]]
15118 <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>
15123 Strip marker in urlencode
15125 {{urlencode:x<nowiki/>y}}
15126 {{urlencode:x<nowiki/>y|wiki}}
15127 {{urlencode:x<nowiki/>y|path}}
15154 Strip marker in formatNum
15156 {{formatnum:1<nowiki/>2}}
15157 {{formatnum:1<nowiki/>2|R}}
15165 Check noCommafy in formatNum
15169 {{formatnum:123456.78}}
15170 {{formatnum:123456.78|NOSEP}}
15178 Strip marker in grammar
15182 {{grammar:elative|foo<nowiki/>bar}}
15189 Strip marker in padleft
15191 {{padleft:|2|x<nowiki/>y}}
15198 Strip marker in padright
15200 {{padright:|2|x<nowiki/>y}}
15207 Strip marker in anchorencode
15209 {{anchorencode:x<nowiki/>y}}
15216 nowiki inside link inside heading (bug 18295)
15218 ==[[foo|x<nowiki>y</nowiki>z]]==
15220 <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>
15225 new support for bdi element (bug 31817)
15227 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
15229 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
15234 Ignore pipe between table row attributes
15238 |- id=foo | style='color: red'
15246 <tr id="foo" style="color: red">
15253 Gallery override link with WikiLink (bug 34852)
15256 File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
15259 <ul class="gallery">
15260 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15261 <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>
15262 <div class="gallerytext">
15272 Gallery override link with absolute external link (bug 34852)
15275 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
15278 <ul class="gallery">
15279 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15280 <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>
15281 <div class="gallerytext">
15291 Gallery override link with malicious javascript (bug 34852)
15294 File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
15297 <ul class="gallery">
15298 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15299 <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>
15300 <div class="gallerytext">
15310 Gallery with invalid title as link (bug 43964)
15313 File:foobar.jpg|link=<
15316 <ul class="gallery">
15317 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
15318 <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>
15319 <div class="gallerytext">
15327 Language parser function
15336 Padleft and padright as substr
15338 {{padleft:|3|abcde}}
15339 {{padright:|3|abcde}}
15347 Special parser function
15349 {{#special:RandomPage}}
15350 {{#special:BaDtItLe}}
15351 {{#special:Foobar}}
15360 Bug 34939 - Case insensitive link parsing ([HttP://])
15362 [HttP://MediaWiki.Org/]
15364 <p><a rel="nofollow" class="external autonumber" href="HttP://MediaWiki.Org/">[1]</a>
15369 Bug 34939 - Case insensitive link parsing ([HttP:// title])
15371 [HttP://MediaWiki.Org/ MediaWiki]
15373 <p><a rel="nofollow" class="external text" href="HttP://MediaWiki.Org/">MediaWiki</a>
15378 Bug 34939 - Case insensitive link parsing (HttP://)
15380 HttP://MediaWiki.Org/
15382 <p><a rel="nofollow" class="external free" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a>
15388 ### Parsoids-specific tests
15389 ### Parsoid-PHP parser incompatibilities
15392 1. SOL-sensitive wikitext tokens as template-args
15394 parsoid=wt2html,wt2wt
15400 <span about="#mwt1" typeof="mw:Transclusion">
15401 </span><ul about="#mwt1"><li>a</li></ul>
15402 <span about="#mwt2" typeof="mw:Transclusion">
15403 </span><ol about="#mwt2"><li>a</li></ol>
15404 <span about="#mwt3" typeof="mw:Transclusion">
15405 </span><dl about="#mwt3"><dd>a</dd></dl>
15408 #### ----------------------------------------------------------------
15409 #### Parsoid-only testing of Parsoid's impl of <ref> and <references>
15410 #### tags. Parsoid's output for these tags differs from that of the
15412 #### ----------------------------------------------------------------
15415 Ref: 1. ref-location should be replaced with an index span
15420 B <ref name="x">foo</ref>
15423 <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>
15424 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>
15425 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>
15429 Ref: 2. ref-tags with identical names should all get the same index
15433 A <ref name="x">foo</ref>
15436 <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>
15437 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>
15441 Ref: 3. spaces in ref-names should be ignored
15445 A <ref name="x">foo</ref>
15446 B <ref name=" x " />
15449 <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>
15450 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>
15451 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>
15455 Ref: 4. 'constructor' should be accepted as a valid ref-name
15456 (NOTE: constructor is a predefined property in JS and constructor as a ref-name can clash with it if not handled properly)
15460 A <ref name="constructor">foo</ref>
15462 <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>
15466 Ref: 5. body should accept generic wikitext
15471 This is a '''[[bolded link]]''' and this is a {{echo|transclusion}}
15476 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"This is a <b data-parsoid=\"{&quot;dsr&quot;:[19,40,3,3]}\"><a rel=\"mw:WikiLink\" href=\"./Bolded_link\" data-parsoid=\"{&quot;a&quot;:{&quot;href&quot;:&quot;./Bolded_link&quot;},&quot;sa&quot;:{&quot;href&quot;:&quot;bolded link&quot;},&quot;stx&quot;:&quot;simple&quot;,&quot;dsr&quot;:[22,37,2,2]}\">bolded link</a></b> and this is a <span about=\"#mwt3\" typeof=\"mw:Transclusion\" data-mw=\"{&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;transclusion&quot;}}}\" data-parsoid=\"{&quot;src&quot;:&quot;{{echo|transclusion}}&quot;,&quot;dsr&quot;:[55,76,null,null]}\">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>
15478 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15479 <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='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"transclusion"}}}'>transclusion</span>
15484 Ref: 6. indent-pres should not be output in ref-body
15496 <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>
15498 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15499 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
15506 Ref: 6. No p-wrapping in ref-body
15525 <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>
15527 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15528 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo
15542 Ref: 8. transclusion wikitext has lower precedence
15546 A <ref> foo {{echo|</ref> B C}}
15550 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"foo <span typeof=\"mw:Nowiki\" data-parsoid=\"{&quot;src&quot;:&quot;{{&quot;,&quot;dsr&quot;:[12,14,2,null]}\">{{</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>
15552 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15553 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <span typeof="mw:Nowiki">{{</span>echo|</li></ol>
15557 Ref: 9. unclosed comments should not leak out of ref-body
15561 A <ref> foo <!--</ref> B C
15565 <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> B C</p>
15567 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15568 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo <!----></li></ol>
15572 Ref: 10. Unclosed HTML tags should not leak out of ref-body
15576 A <ref> <b> foo </ref> B C
15580 <p>A <span about="#mwt1" class="reference" data-mw='{"name":"ref","body":{"html":"<b data-parsoid=\"{&quot;stx&quot;:&quot;html&quot;,&quot;autoInsertedEnd&quot;:true,&quot;dsr&quot;:[8,16,3,0]}\"> foo </b>"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span> B C</p>
15582 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references">
15583 <li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> <b> foo </b></li></ol>
15587 Ref: 11. ref-tags acts like an inline element wrt P-wrapping
15594 <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> B
15595 C <span about="#mwt2" 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">[2]</a></span> D</p>
15599 Ref: 12. ref-tags act as trailing newline migration barrier
15603 <!--the newline at the end of this line moves out of the p-tag-->a
15605 b<!--the newline at the end of this line stays inside the p-tag--> <ref />
15610 <p><!--the newline at the end of this line moves out of the p-tag-->a</p>
15613 <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>
15614 <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>
15621 Ref: 13. ref-tags are not SOL-transparent and block indent-pres
15629 <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
15630 <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>
15634 Ref: 14. A nested ref-tag should be emitted as plain text
15638 <ref>foo <ref>bar</ref> baz</ref>
15642 <p><span about="#mwt1" class="reference" data-mw="{"name":"ref","body":{"html":"foo &lt;ref&gt;bar&lt;/ref&gt; baz"},"attrs":{}}" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
15644 <ol class="references" typeof="mw:Extension/references" about="#mwt2" data-mw="{"name":"references","attrs":{}}">
15645 <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></ol>
15649 Ref: 15. ref-tags with identical names should get identical indexes
15653 A1 <ref name="a">foo</ref> A2 <ref name="a" />
15654 B1 <ref name="b" /> B2 <ref name="b">bar</ref>
15658 <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>
15659 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>
15661 <ol about="#mwt10" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references"><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></ol>
15665 References: 1. references tag without any refs should be handled properly
15671 <ol about="#mwt2" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references"></ol>
15675 References: 2. references tag with group only outputs references from that group
15679 A <ref group="a">foo</ref>
15680 B <ref group="b">bar</ref>
15682 <references group='a' />
15684 <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>
15685 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{"group":"b"}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[b 1]</a></span></p>
15687 <ol about="#mwt6" class="references" data-mw='{"name":"references","attrs":{"group":"a"}}' typeof="mw:Extension/references"><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li></ol>
15691 References: 3. ref list should be cleared after processing references
15703 <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>
15705 <ol about="#mwt4" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references"><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> foo</li></ol>
15707 <p>B <span about="#mwt6" class="reference" data-mw='{"name":"ref","body":{"html":"bar"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span></p>
15709 <ol about="#mwt8" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references"><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> bar</li></ol>
15713 References: 4. only referenced group should be cleared after processing references
15717 A <ref group="a">afoo</ref>
15720 <references group="a"/>
15726 <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>
15727 B <span about="#mwt4" class="reference" data-mw='{"name":"ref","body":{"html":"bfoo"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid='{"src":"<ref>bfoo</ref>","dsr":[30,45,5,6]}'><a href="#cite_note-1">[1]</a></span></p>
15729 <ol about="#mwt6" class="references" data-mw='{"name":"references","attrs":{"group":"a"}}' typeof="mw:Extension/references"><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> afoo</li></ol>
15731 <p>C <span about="#mwt8" class="reference" data-mw='{"name":"ref","body":{"html":"cfoo"},"attrs":{}}' id="cite_ref-2-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-2">[2]</a></span></p>
15733 <ol about="#mwt10" class="references" data-mw='{"name":"references","attrs":{}}' typeof="mw:Extension/references"><li about="#cite_note-1" id="cite_note-1"><span rel="mw:referencedBy"><a href="#cite_ref-1-0">↑</a></span> bfoo</li><li about="#cite_note-2" id="cite_note-2"><span rel="mw:referencedBy"><a href="#cite_ref-2-0">↑</a></span> cfoo</li></ol>
15737 References: 5. ref tags in references should be processed while ignoring all other content
15742 B <ref name="b">bar</ref>
15745 <ref name="a">foo</ref>
15746 This should just get lost.
15749 <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"><a href="#cite_note-a-1">[1]</a></span>
15750 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"><a href="#cite_note-b-2">[2]</a></span></p>
15752 <ol class="references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","body":{"extsrc":"<ref name=\"a\">foo</ref>\nThis should just get lost.","html":"<span about=\"#mwt8\" class=\"reference\" data-mw=\"{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;foo&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;a&quot;}}\" rel=\"dc:references\" typeof=\"mw:Extension/ref\"><a href=\"#cite_note-a-1\">[1]</a></span>"},"attrs":{}}'><li about="#cite_note-a-1" id="cite_note-a-1"><span rel="mw:referencedBy"><a href="#cite_ref-a-1-0">↑</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">↑</a></span> bar</li></ol>
15756 References: 6. <references /> from a transclusion
15760 {{echo|<references />}}
15762 <ol class="references" about="#mwt2" typeof="mw:Transclusion" data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<references />"}},"i":0}'></ol>
15766 References: 7. Multiple references tags (one without and one with nested refs) should be correctly handled
15770 A <ref>foo bar for a</ref>
15776 <ref name="b">foo</ref>
15779 <p>A <span about="#mwt2" class="reference" data-mw='{"name":"ref","body":{"html":"foo bar for a"},"attrs":{}}' id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-1">[1]</a></span>
15780 B <span about="#mwt4" 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></p>
15782 <ol class="references" typeof="mw:Extension/references" about="#mwt6" 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 bar for a</li><li about="#cite_note-b-2" id="cite_note-b-2"><span rel="mw:referencedBy"><a href="#cite_ref-b-2-0">↑</a></span> </li></ol>
15784 <ol class="references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","body":{"extsrc":"<ref name=\"b\">foo</ref>","html":"\n<span about=\"#mwt10\" class=\"reference\" data-mw=\"{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;foo&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;b&quot;}}\" rel=\"dc:references\" typeof=\"mw:Extension/ref\"><a href=\"#cite_note-b-1\">[1]</a></span>\n"},"attrs":{}}'><li about="#cite_note-b-1" id="cite_note-b-1"><span rel="mw:referencedBy">↑</span> foo</li></ol>
15788 #### ----------------------------------------------------------------
15789 #### The following section of tests are primarily to test
15790 #### wikitext escaping capabilities of Parsoid. Given that
15791 #### escaping can be done any number of ways, the wikitext (input)
15792 #### is always adjusted to reflect how Parsoid adds nowiki
15795 #### We are marking several tests as parsoid-only since the
15796 #### HTML in the result section is different from what the
15797 #### PHP parser generates for it.
15798 #### ----------------------------------------------------------------
15801 #### --------------- Headings ---------------
15803 #### 1. Nested inside html <h1>=foo=</h1>
15804 #### 2. Outside heading nest on a single line <h1>foo</h1>*bar
15805 #### 3. Nested inside html with wikitext split by html tags
15806 #### 4. No escape needed
15807 #### 5. Empty headings <h1></h1>
15808 #### 6. Heading chars in SOL context
15809 #### ----------------------------------------
15811 Headings: 0. Unnested
15815 <nowiki>=foo=</nowiki>
15817 <nowiki> =foo= </nowiki>
15819 <nowiki>=foo=</nowiki>
15821 =foo''a''<nowiki>=</nowiki>
15823 <p><span typeof="mw:Nowiki">=foo=</span></p>
15825 <p><span typeof="mw:Nowiki"> =foo= </span>
15827 <span typeof="mw:Nowiki">=foo=</span></p>
15829 <p>=foo<i>a</i><span typeof="mw:Nowiki">=</span></p>
15833 Headings: 1. Nested inside html
15837 =<nowiki>=foo=</nowiki>=
15839 ==<nowiki>=foo=</nowiki>==
15841 ===<nowiki>=foo=</nowiki>===
15843 ====<nowiki>=foo=</nowiki>====
15845 =====<nowiki>=foo=</nowiki>=====
15847 ======<nowiki>=foo=</nowiki>======
15849 <h1><span typeof="mw:Nowiki">=foo=</span></h1>
15850 <h2><span typeof="mw:Nowiki">=foo=</span></h2>
15851 <h3><span typeof="mw:Nowiki">=foo=</span></h3>
15852 <h4><span typeof="mw:Nowiki">=foo=</span></h4>
15853 <h5><span typeof="mw:Nowiki">=foo=</span></h5>
15854 <h6><span typeof="mw:Nowiki">=foo=</span></h6>
15858 Headings: 2. Outside heading nest on a single line <h1>foo</h1>*bar
15863 <nowiki>*</nowiki>bar
15869 <nowiki>=bar=</nowiki>
15877 Headings: 3. Nested inside html with wikitext split by html tags
15881 =='''bold'''<nowiki>foo=</nowiki>=
15883 <h1>=<b>bold</b><span typeof="mw:Nowiki">foo=</span></h1>
15887 Headings: 4a. No escaping needed (testing just h1 and h2)
15905 =<nowiki>=</nowiki>=
15913 <h1><i>=</i>foo=</h1>
15914 <h1><span typeof="mw:Nowiki">=</span></h1>
15918 Headings: 4b. No escaping needed (inside p-tags)
15933 Headings: 5. Empty headings
15945 =====<nowiki/>=====
15947 ======<nowiki/>======
15958 Headings: 6a. Heading chars in SOL context (with trailing spaces)
15962 <nowiki>=a=</nowiki>
15964 <nowiki>=a=</nowiki>
15966 <nowiki>=a=</nowiki>
15968 <nowiki>=a=</nowiki>
15977 Headings: 6b. Heading chars in SOL context (with trailing newlines)
16005 Headings: 6c. Heading chars in SOL context (leading newline break)
16010 <nowiki>=b=</nowiki>
16017 Headings: 6d. Heading chars in SOL context (with interspersed comments)
16021 <!--c0--><nowiki>=a=</nowiki>
16023 <nowiki>=a=</nowiki> <!--c2--> <!--c3-->
16025 <p><!--c0-->=a=</p>
16026 <p><!--c1-->=a= <!--c2--> <!--c3--></p>
16030 Headings: 6d. Heading chars in SOL context (No escaping needed)
16039 #### --------------- Lists ---------------
16040 #### 0. Outside nests (*foo, etc.)
16041 #### 1. Nested inside html <ul><li>*foo</li></ul>
16042 #### 2. Inside definition lists
16043 #### 3. Only bullets at start should be escaped
16044 #### 4. No escapes needed
16045 #### 5. No unnecessary escapes
16046 #### 6. Escape bullets in SOL position
16047 #### 7. Escape bullets in a multi-line context
16048 #### ----------------------------------------
16051 Lists: 0. Outside nests
16053 <nowiki>*</nowiki>foo
16055 <nowiki>#</nowiki>foo
16063 Lists: 1. Nested inside html
16065 *<nowiki>*foo</nowiki>
16067 *<nowiki>#foo</nowiki>
16069 *<nowiki>:foo</nowiki>
16071 *<nowiki>;foo</nowiki>
16073 #<nowiki>*foo</nowiki>
16075 #<nowiki>#foo</nowiki>
16077 #<nowiki>:foo</nowiki>
16079 #<nowiki>;foo</nowiki>
16101 Lists: 2. Inside definition lists
16103 ;<nowiki>;foo</nowiki>
16105 ;<nowiki>:foo</nowiki>
16107 ;<nowiki>:foo</nowiki>
16110 :<nowiki>:foo</nowiki>
16125 Lists: 3. Only bullets at start of text should be escaped
16127 *<nowiki>*foo*bar</nowiki>
16129 *<nowiki>*foo</nowiki>''it''*bar
16133 <ul><li>*foo<i>it</i>*bar
16139 Lists: 4. No escapes needed
16151 <ul><li><i>foo</i>*bar
16153 <ul><li><a rel="mw:WikiLink" href="Foo">Foo</a>: bar
16158 Lists: 5. No unnecessary escapes
16160 * bar <span><nowiki>[[foo]]</nowiki></span>
16162 *=bar <span><nowiki>[[foo]]</nowiki></span>
16164 *[[bar <span><nowiki>[[foo]]</nowiki></span>
16166 *]]bar <span><nowiki>[[foo]]</nowiki></span>
16168 *=bar <span>foo]]</span>=
16172 <ul><li> bar <span>[[foo]]</span>
16174 <ul><li>=bar <span>[[foo]]</span>
16176 <ul><li>[[bar <span>[[foo]]</span>
16178 <ul><li>]]bar <span>[[foo]]</span>
16180 <ul><li>=bar <span>foo]]</span>=
16182 <ul><li> <s></s>: a
16188 Lists: 6. Escape bullets in SOL position
16192 <!--cmt--><nowiki>*foo</nowiki>
16194 <p><!--cmt--><span typeof="mw:Nowiki">*foo</span></p>
16198 Lists: 7. Escape bullets in a multi-line context
16201 <nowiki>*</nowiki>b
16208 #### --------------- HRs ---------------
16209 #### 1. Single line
16210 #### -----------------------------------
16213 HRs: 1. Single line
16217 ----<nowiki>----</nowiki>
16221 <hr><span typeof="mw:Nowiki">----</span>
16226 #### --------------- Tables ---------------
16227 #### 1a. Simple example
16228 #### 1b. No escaping needed (!foo)
16229 #### 1c. No escaping needed (|foo)
16230 #### 1d. No escaping needed (|}foo)
16232 #### 2a. Nested in td (<td>foo|bar</td>)
16233 #### 2b. Nested in td (<td>foo||bar</td>)
16234 #### 2c. Nested in td -- no escaping needed(<td>foo!!bar</td>)
16236 #### 3a. Nested in th (<th>foo!bar</th>)
16237 #### 3b. Nested in th (<th>foo!!bar</th>)
16238 #### 3c. Nested in th -- no escaping needed(<th>foo||bar</th>)
16242 #### 4c. No escaping needed
16243 #### --------------------------------------
16246 Tables: 1a. Simple example
16257 Tables: 1b. No escaping needed
16266 Tables: 1c. No escaping needed
16275 Tables: 1d. No escaping needed
16284 Tables: 2a. Nested in td
16289 |<nowiki>foo|bar</nowiki>
16293 <td><span typeof="mw:Nowiki">foo|bar</span></td></tr></tbody></table>
16297 Tables: 2b. Nested in td
16302 |<nowiki>foo||bar</nowiki>
16303 |''it''<nowiki>foo||bar</nowiki>
16307 <td><span typeof="mw:Nowiki">foo||bar</span></td>
16308 <td><i>it</i><span typeof="mw:Nowiki">foo||bar</span></td></tr></tbody></table>
16312 Tables: 2c. Nested in td -- no escaping needed
16320 <table><tbody><tr><td>foo!!bar
16321 </td></tr></tbody></table>
16326 Tables: 3a. Nested in th
16334 <table><tbody><tr><th>foo!bar
16335 </th></tr></tbody></table>
16340 Tables: 3b. Nested in th
16345 !<nowiki>foo!!bar</nowiki>
16349 <tbody><tr><th><span typeof="mw:Nowiki">foo!!bar</span></th></tr>
16354 Tables: 3c. Nested in th -- no escaping needed
16359 !<nowiki>foo||bar</nowiki>
16363 <th><span typeof="mw:Nowiki">foo||bar</span></th></tr></tbody></table>
16367 Tables: 4a. Escape -
16375 |<nowiki>-bar</nowiki>
16379 <tr><th>-bar</th></tr>
16381 <td><span typeof="mw:Nowiki">-bar</span></td></tr></tbody></table>
16385 Tables: 4b. Escape +
16393 |<nowiki>+bar</nowiki>
16397 <tr><th>+bar</th></tr>
16399 <td><span typeof="mw:Nowiki">+bar</span></td></tr></tbody></table>
16403 Tables: 4c. No escaping needed
16422 <tr><td>foo-bar</td><td>foo+bar</td></tr>
16423 <tr><td><i>foo</i>-bar</td><td><i>foo</i>+bar</td></tr>
16431 ### SSS FIXME: Disabled right now because accurate html2wt
16432 ### on this snippet requires data-parsoid flags that we've
16433 ### stripped out of these tests. We should scheme how we
16434 ### we want to handle these kind of tests that require
16435 ### data-parsoid flags for accurate html2wt serialization
16438 Tables: 4d. No escaping needed
16456 #### --------------- Links ----------------
16457 #### 1. Quote marks in link text
16458 #### 2. Wikilinks: Escapes needed
16459 #### 3. Wikilinks: No escapes needed
16460 #### 4. Extlinks: Escapes needed
16461 #### 5. Extlinks: No escapes needed
16462 #### --------------------------------------
16464 Links 1. Quote marks in link text
16468 [[Foo|Foo<nowiki>''boo''</nowiki>]]
16470 <a rel="mw:WikiLink" href="Foo">Foo''boo''</a>
16474 Links 2. WikiLinks: Escapes needed
16478 [[Foo|<nowiki>[Foobar]</nowiki>]]
16479 [[Foo|<nowiki>Foobar]</nowiki>]]
16480 [[Foo|x [Foobar] x]]
16481 [[Foo|<nowiki>x [http://google.com g] x</nowiki>]]
16482 [[Foo|<nowiki>[[Bar]]</nowiki>]]
16483 [[Foo|<nowiki>x [[Bar]] x</nowiki>]]
16484 [[Foo|<nowiki>|Bar</nowiki>]]
16485 [[Foo|<nowiki>]]bar</nowiki>]]
16486 [[Foo|<nowiki>[[bar</nowiki>]]
16487 [[Foo|<nowiki>x ]] y [[ z</nowiki>]]
16489 <a href="Foo" rel="mw:WikiLink">[Foobar]</a>
16490 <a href="Foo" rel="mw:WikiLink">Foobar]</a>
16491 <a href="Foo" rel="mw:WikiLink">x [Foobar] x</a>
16492 <a href="Foo" rel="mw:WikiLink">x [http://google.com g] x</a>
16493 <a href="Foo" rel="mw:WikiLink">[[Bar]]</a>
16494 <a href="Foo" rel="mw:WikiLink">x [[Bar]] x</a>
16495 <a href="Foo" rel="mw:WikiLink">|Bar</a>
16496 <a href="Foo" rel="mw:WikiLink">]]bar</a>
16497 <a href="Foo" rel="mw:WikiLink">[[bar</a>
16498 <a href="Foo" rel="mw:WikiLink">x ]] y [[ z</a>
16502 Links 3. WikiLinks: No escapes needed
16509 <a href="Foo" rel="mw:WikiLink">[Foobar</a>
16510 <a href="Foo" rel="mw:WikiLink">foo|bar</a>
16514 Links 4. ExtLinks: Escapes needed
16518 [http://google.com <nowiki>[google]</nowiki>]
16519 [http://google.com <nowiki>google]</nowiki>]
16521 <a href="http://google.com" rel="mw:ExtLink">[google]</a>
16522 <a href="http://google.com" rel="mw:ExtLink">google]</a>
16526 Links 5. ExtLinks: No escapes needed
16530 [http://google.com [google]
16532 <a href="http://google.com" rel="mw:ExtLink">[google</a>
16535 #### --------------- Quotes ---------------
16536 #### 1. Quotes inside <b> and <i>
16537 #### 2. Link fragments separated by <i> and <b> tags
16538 #### 3. Link fragments inside <i> and <b>
16539 #### 4. No escaping needed
16540 #### --------------------------------------
16542 1. Quotes inside <b> and <i>
16544 parsoid=html2wt,wt2wt
16546 ''<nowiki>'foo'</nowiki>''
16547 ''<nowiki>''foo''</nowiki>''
16548 ''<nowiki>'''foo'''</nowiki>''
16550 '''<nowiki>'foo'</nowiki>'''
16551 '''<nowiki>''foo''</nowiki>'''
16552 '''<nowiki>'''foo'''</nowiki>'''
16553 '''<nowiki>foo'</nowiki>''<nowiki>bar'</nowiki>''baz'''
16554 '''foo'''<nowiki/>'s
16557 '<nowiki/>''foo''<nowiki/>'
16559 '''foo'''<nowiki/>'
16560 '<nowiki/>'''foo'''<nowiki/>'
16569 <b>foo'<i>bar'</i>baz</b>
16580 2. Link fragments separated by <i> and <b> tags
16582 [[''foo''<nowiki>hello]]</nowiki>
16584 [['''foo'''<nowiki>hello]]</nowiki>
16586 <p>[[<i>foo</i>hello]]
16587 </p><p>[[<b>foo</b>hello]]
16592 3. Link fragments inside <i> and <b>
16593 (FIXME: Escaping one or both of [[ and ]] is also acceptable --
16594 this is one of the shortcomings of this format)
16596 ''[[foo''<nowiki>]]</nowiki>
16598 '''[[foo'''<nowiki>]]</nowiki>
16601 </p><p><b>[[foo</b>]]
16606 4. No escaping needed
16608 '<span>''bar''</span>'
16609 '<span>'''bar'''</span>'
16611 <p>'<span><i>bar</i></span>'
16612 '<span><b>bar</b></span>'
16616 #### ----------- Paragraphs ---------------
16617 #### 1. No unnecessary escapes
16618 #### --------------------------------------
16621 1. No unnecessary escapes
16623 bar <span><nowiki>[[foo]]</nowiki></span>
16625 =bar <span><nowiki>[[foo]]</nowiki></span>
16627 [[bar <span><nowiki>[[foo]]</nowiki></span>
16629 ]]bar <span><nowiki>[[foo]]</nowiki></span>
16631 =bar <span>foo]]</span><nowiki>=</nowiki>
16633 <p>bar <span>[[foo]]</span>
16634 </p><p>=bar <span>[[foo]]</span>
16635 </p><p>[[bar <span>[[foo]]</span>
16636 </p><p>]]bar <span>[[foo]]</span>
16637 </p><p>=bar <span>foo]]</span>=
16641 #### ----------------------- PRE --------------------------
16642 #### 1. Leading whitespace in SOL context should be escaped
16643 #### ------------------------------------------------------
16645 1. Leading whitespace in SOL context should be escaped
16649 <nowiki> </nowiki>a
16651 <nowiki> </nowiki> a
16653 <nowiki> </nowiki>a(tab)
16655 <nowiki> </nowiki> a
16657 <nowiki> </nowiki> a
16660 <nowiki> </nowiki>b
16663 <nowiki> </nowiki>b
16666 <nowiki> </nowiki> b
16672 <p><!--cmt--> a</p>
16681 #### --------------- HTML tags ---------------
16684 #### 3. multi-line html tag
16685 #### -----------------------------------------
16691 <a href="http://google.com">google</a>
16693 <a href="http://google.com">google</a>
16699 <nowiki><div>foo</div>
16700 <div style="color:red">foo</div></nowiki>
16702 <p><div>foo</div>
16703 <div style="color:red">foo</div>
16708 3. multi-line html tag
16723 <nowiki><ref>foo</ref></nowiki>
16725 <p><ref>foo</ref>
16729 #### --------------- Others ---------------
16733 <nowiki>foo</nowiki>
16735 <p><nowiki>foo</nowiki>
16739 ## The quote-char in the input is necessary for triggering the bug
16741 (Bug 52035) Nowiki-escaping should not get tripped by " :" in text
16743 parsoid=wt2wt,html2wt
16752 Tag-like HTML structures are passed through as text
16774 </p><p>1<d e>f
16779 # This was a bug in the PHP parser (see bug 17663 and its dups,
16780 # https://bugzilla.wikimedia.org/show_bug.cgi?id=17663)
16782 Tag names followed by punctuation should not be recognized as tags
16786 <p><s.ome> text
16791 HTML tag with necessary entities in attributes
16793 <span title="&amp;">foo</span>
16795 <p><span title="&amp;">foo</span>
16800 HTML tag with 'unnecessary' entity encoding in attributes
16802 <span title="&">foo</span>
16804 <p><span title="&">foo</span>
16809 HTML tag with broken attribute value quoting
16811 <span title="Hello world>Foo</span>
16813 <p><span>Foo</span>
16818 Parsoid-only: HTML tag with broken attribute value quoting
16822 <span title="Hello world>Foo</span>
16824 <p><span title="Hello world">Foo</span>
16829 Table with broken attribute value quoting
16832 | title="Hello world|Foo
16843 Table with broken attribute value quoting on consecutive lines
16846 | title="Hello world|Foo
16847 | style="color:red|Bar
16860 Parsoid-only: Table with broken attribute value quoting on consecutive lines
16865 | title="Hello world|Foo
16866 | style="color:red|Bar
16871 <td title="Hello world">Foo
16872 </td><td style="color: red">Bar
16873 </td></tr></tbody></table>
16878 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
16888 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
16898 Accept empty td cell attribute
16901 | align="center" | foo || |
16906 <td align="center"> foo </td>
16913 Non-empty attributes in th-cells
16916 ! Foo !! style="color: red" | Bar
16922 <th style="color: red"> Bar
16928 Accept empty attributes in th-cells
16943 Empty table rows go away
16964 ### Parsoid-centric tests for testing RTing of inter-element separators
16965 ### Edge cases not tested by existing parser tests and specific to
16966 ### Parsoid-specific serialization strategies.
16970 RT-ed inter-element separators should be valid separators
16983 Trailing newlines in a deep dom-subtree that ends a wikitext line should be migrated out
16984 (Parsoid-only since PHP parser relies on Tidy for correct output)
17000 Empty TD followed by TD with tpl-generated attribute
17005 |{{echo|style='color:red'}}|foo
17019 Indented table with an empty td
17038 Empty TR followed by a template-generated TR
17039 (Parsoid-specific since PHP parser doesn't handle this mixed tbl-wikitext)
17041 parsoid=wt2html,wt2wt
17045 {{echo|<tr><td>foo</td></tr>}}
17051 <tr typeof="mw:Transclusion">
17052 <td>foo</td></tr></tbody></table>
17055 ## PHP and parsoid output differ for this, and since this is primarily
17056 ## for testing Parsoid's serializer, marking this Parsoid only
17058 Empty TR followed by mixed-ws-comment line should RT correctly
17072 <td> <!--c--></td></tr>
17074 <td><!--c--> <!--d--></td></tr>
17080 Multi-line image caption generated by templates with/without trailing newlines
17084 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}]]
17085 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}\n\n]]
17087 <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>
17088 <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>
17092 ## PHP emits broken html for this, and since this is primarily
17093 ## a Parsoid serializer test, marking this Parsoid only
17095 Improperly nested inline or quotes tags with whitespace in between
17099 <span> <s>x</span> </s>
17102 <p><span> <s>x</s></span><s> </s>
17103 <b> <i>x</i></b><i> </i>
17108 Encapsulate protected attributes from wt
17112 <div typeof="mw:placeholder stuff" data-parsoid="weird" data-parsoid-other="no" about="time" rel="mw:true">foo</div>
17114 <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>
17118 # -----------------------------------------------------------------
17119 # The following section of tests are primarily to spec requirements
17120 # around serialization of new/edited content.
17122 # All these tests are marked Parsoid html2wt and html2html only
17123 # ----------------------------------------------------------------
17126 Image: Modifying size of an image
17130 [[Image:Wiki.png|230x230px]]
17132 <p data-parsoid='{"dsr":[0,24,0,0]}'><span typeof="mw:Image" data-parsoid='{"optList":[{"ck":"width","ak":"100px"}],"cacheKey":"[[Image:Wiki.png|100px]]","img":{"h":115,"w":100,"wdset":true},"dsr":[0,24,null,null]}'><a href="./File:Wiki.png" data-parsoid='{"a":{"href":"./File:Wiki.png"}}'><img resource="./File:Wiki.png" src="//upload.wikimedia.org/wikipedia/en/thumb/b/bc/Wiki.png/100px-Wiki.png" height="230" width="200" data-parsoid='{"a":{"resource":"./File:Wiki.png"},"sa":{"resource":"Image:Wiki.png"}}'></a></span></p>
17136 Image: New block level image should have \n before and after
17141 [[File:Wiki.png|right|thumb|150x150px]]
17144 <p>123</p><figure typeof="mw:Image/Thumb" class="mw-halign-right"><a href="./File:Wiki.png"><img src="http://192.168.142.128/mw/images/thumb/b/bc/Wiki.png/131px-Wiki.png" width="131" height="150" resource="./File:Wiki.png"></a></figure><p>456</p>
17147 # Wacky -- the leading newline in input is required because
17148 # that is what the serializer emits. To be fixed. Not fixing
17149 # the test because this test is required to test serialization of
17150 # new content and preferred whitespace style.
17152 Lists: Add space after bullets
17159 * <span> baz</span>
17164 <li><span> baz</span></li>
17169 Parsoid: Serialize positional parameters with = in them as named parameter
17175 <p about="#mwt1" typeof="mw:Transclusion"
17176 data-mw='{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"f=oo"}},"i":0}'
17180 # -----------------------------------------------------------------
17181 # End of section for Parsoid-only html2wt tests for serialization
17183 # -----------------------------------------------------------------
17190 Try for 100% code coverage