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 # For testing purposes, temporary articles can created:
31 # !!article / NAMESPACE:TITLE / !!text / ARTICLE TEXT / !!endarticle
32 # where '/' denotes a newline.
34 # This is the standard article assumed to exist.
59 MediaWiki:bad image list
61 * [[File:Bad.jpg]] except [[Nasty page]]
95 Template:echo_with_span
101 Template:echo_with_div
113 Template:table_attribs
116 |</noinclude>style="color: red"| Foo
138 This is a simple paragraph.
140 <p>This is a simple paragraph.
145 Paragraphs with extra newline spacing
168 Paragraphs with newline spacing with comment lines in between
176 <!--foo--><!--More than 1 comment disables stripping of this line!-->
233 Paragraphs with newline spacing with non-empty white-space lines in between
260 Paragraphs with newline spacing with non-empty mixed comment and white-space lines in between
268 <!--foo--><!--More than 1 comment disables stripping of this line!-->
309 http://fr.wikipedia.org/wiki/🍺
310 <!-- EasterEgg we love beer, better be able be able to link to it -->
312 <p><a rel="nofollow" class="external free" href="http://fr.wikipedia.org/wiki/🍺">http://fr.wikipedia.org/wiki/🍺</a>
332 * plain''italic''plain
333 * plain''italic''plain''italic''plain
334 * plain'''bold'''plain
335 * plain'''bold'''plain'''bold'''plain
336 * plain''italic''plain'''bold'''plain
337 * plain'''bold'''plain''italic''plain
338 * plain''italic'''bold-italic'''italic''plain
339 * plain'''bold''bold-italic''bold'''plain
340 * plain'''''bold-italic'''italic''plain
341 * plain'''''bold-italic''bold'''plain
342 * plain''italic'''bold-italic'''''plain
343 * plain'''bold''bold-italic'''''plain
344 * plain l'''italic''plain
345 * plain l''''bold''' plain
348 </li><li> plain<i>italic</i>plain
349 </li><li> plain<i>italic</i>plain<i>italic</i>plain
350 </li><li> plain<b>bold</b>plain
351 </li><li> plain<b>bold</b>plain<b>bold</b>plain
352 </li><li> plain<i>italic</i>plain<b>bold</b>plain
353 </li><li> plain<b>bold</b>plain<i>italic</i>plain
354 </li><li> plain<i>italic<b>bold-italic</b>italic</i>plain
355 </li><li> plain<b>bold<i>bold-italic</i>bold</b>plain
356 </li><li> plain<i><b>bold-italic</b>italic</i>plain
357 </li><li> plain<b><i>bold-italic</i>bold</b>plain
358 </li><li> plain<i>italic<b>bold-italic</b></i>plain
359 </li><li> plain<b>bold<i>bold-italic</i></b>plain
360 </li><li> plain l'<i>italic</i>plain
361 </li><li> plain l'<b>bold</b> plain
367 ### 2-quote opening sequence tests
370 Italics and bold: 2-quote opening sequence: (2,2)
380 Italics and bold: 2-quote opening sequence: (2,3)
390 Italics and bold: 2-quote opening sequence: (2,4)
400 Italics and bold: 2-quote opening sequence: (2,5) (php)
409 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
411 Italics and bold: 2-quote opening sequence: (2,5) (parsoid)
423 ### 3-quote opening sequence tests
427 Italics and bold: 3-quote opening sequence: (3,2)
437 Italics and bold: 3-quote opening sequence: (3,3)
447 Italics and bold: 3-quote opening sequence: (3,4)
457 Italics and bold: 3-quote opening sequence: (3,5) (php)
466 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
468 Italics and bold: 3-quote opening sequence: (3,5) (parsoid)
480 ### 4-quote opening sequence tests
484 Italics and bold: 4-quote opening sequence: (4,2)
494 Italics and bold: 4-quote opening sequence: (4,3)
504 Italics and bold: 4-quote opening sequence: (4,4)
514 Italics and bold: 4-quote opening sequence: (4,5) (php)
523 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
525 Italics and bold: 4-quote opening sequence: (4,5) (parsoid)
531 <p>'<b>foo<i></i></b>
537 ### 5-quote opening sequence tests
541 Italics and bold: 5-quote opening sequence: (5,2) (php)
550 # Parsoid reverses the nesting order, compared to the PHP parser
552 Italics and bold: 5-quote opening sequence: (5,2) (parsoid)
564 Italics and bold: 5-quote opening sequence: (5,3)
574 Italics and bold: 5-quote opening sequence: (5,4)
578 <p><i><b>foo'</b></i>
584 Italics and bold: 5-quote opening sequence: (5,5)
593 ### multiple quote sequences in a line
596 Italics and bold: multiple quote sequences: (2,4,2)
600 <p><i>foo'<b>bar</b></i>
606 Italics and bold: multiple quote sequences: (2,4,3)
610 <p><i>foo'<b>bar</b></i>
616 Italics and bold: multiple quote sequences: (2,4,4)
620 <p><i>foo'<b>bar'</b></i>
626 Italics and bold: multiple quote sequences: (3,4,2) (php)
635 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
637 Italics and bold: multiple quote sequences: (3,4,2) (parsoid)
643 <p><b>foo'</b>bar<i></i>
649 Italics and bold: multiple quote sequences: (3,4,3) (php)
658 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
660 Italics and bold: multiple quote sequences: (3,4,3) (parsoid)
666 <p><b>foo'</b>bar<b></b>
671 ### other quote tests
674 Italics and bold: other quote tests: (2,3,5)
676 ''this is about '''foo's family'''''
678 <p><i>this is about <b>foo's family</b></i>
684 Italics and bold: other quote tests: (2,(3,3),2)
686 ''this is about '''foo's''' family''
688 <p><i>this is about <b>foo's</b> family</i>
694 Italics and bold: other quote tests: (3,2,3,2)
696 '''this is about ''foo'''s family''
698 <p><b>this is about <i>foo</i></b><i>s family</i>
703 # The Parsoid team believes the PHP parser's output on this test is wrong.
704 # It only checks for convert-to-bold-on-single-character-word when the word
705 # matches with a bold tag ("'''") that is *odd* in the list of quote tokens.
706 # This means that the bold token in position 2 (0-indexed) gets converted by
707 # parsoid, but doesn't get changed by the PHP parser.
709 Italics and bold: other quote tests: (3,2,3,3) (php)
713 '''this is about ''foo'''s family'''
715 <p>'<i>this is about </i>foo<b>s family</b>
718 # This is the output the Parsoid team believes to be correct.
720 Italics and bold: other quote tests: (3,2,3,3) (parsoid)
724 '''this is about ''foo'''s family'''
726 <p><b>this is about <i>foo'</i>s family</b>
732 Italics and bold: other quote tests: (3,(2,2),3)
734 '''this is about ''foo's'' family'''
736 <p><b>this is about <i>foo's</i> family</b>
742 Italicized possessive
744 The ''[[Main Page]]'''s talk page.
746 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
755 Non-html5 tags should be accepted
757 <center>''foo''</center>
760 <strike>''foo''</strike>
763 <center><i>foo</i></center>
764 <p><big><i>foo</i></big>
765 <font><i>foo</i></font>
766 <strike><i>foo</i></strike>
772 ### <nowiki> test cases
776 <nowiki> unordered list
778 <nowiki>* This is not an unordered list item.</nowiki>
780 <p>* This is not an unordered list item.
787 <nowiki>Lorem ipsum dolor
808 :There is not nowiki.
809 :There is <nowiki>nowiki</nowiki>.
811 #There is not nowiki.
812 #There is <nowiki>nowiki</nowiki>.
814 *There is not nowiki.
815 *There is <nowiki>nowiki</nowiki>.
817 <dl><dd>There is not nowiki.
818 </dd><dd>There is nowiki.
820 <ol><li>There is not nowiki.
821 </li><li>There is nowiki.
823 <ul><li>There is not nowiki.
824 </li><li>There is nowiki.
830 Entities inside <nowiki>
832 <nowiki><</nowiki>
843 Comments and Indent-Pre
845 <!-- comment 1 --> asdf
847 <!-- comment 1 --> asdf
850 <!-- comment 1 --> asdf
851 <!-- comment 2 -->xyz
853 <!-- comment 1 --> asdf
854 <!-- comment 2 --> xyz
910 asdf<!-- comment 1 -->jkl
920 <!-- foo --> b <!-- bar -->
934 <!-- returns a single newline, not nothing, since the newline after > is not stripped -->
940 Comment semantics and delimiters
942 <!-- --><!----><!-----><!------>
948 Comment semantics and delimiters, redux
950 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
951 -- foo -- funky huh? ... -->
957 Comment semantics and delimiters: directors cut
959 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
960 everything starting with < followed by !-- until the first -- and > we see,
961 that wouldn't be valid XML however, since in XML -- has to terminate a comment
969 Comment semantics: nesting
971 <!--<!-- no, we're not going to do anything fancy here -->-->
978 Comment semantics: unclosed comment at end
980 <!--This comment will run out to the end of the document
986 Comment in template title
995 Comment on its own line post-expand
1007 Comment on its own line post-expand with non-significant whitespace
1019 ### paragraph wraping tests
1033 Block tag on one line
1045 Block tag on both lines
1057 Multiple lines without block tags
1075 Empty lines between lines with block tags
1105 ### Preformatted text
1114 And a [[Main Page|link]]
1120 And a <a href="/wiki/Main_Page" title="Main Page">link</a>
1125 Ident preformatting with inline content
1136 <pre> with <nowiki> inside (compatibility with 1.6 and earlier)
1153 Regression with preformatted in <center>
1166 # Expected output in the following test is not really expected (there should be
1167 # <pre> in the output) -- it's only testing for well-formedness.
1169 Bug 6200: Preformatted in <blockquote>
1182 <pre> with attributes (bug 3202)
1184 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1186 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
1191 <pre> with width attribute (bug 3202)
1193 <pre width="8">Narrow screen goodies</pre>
1195 <pre width="8">Narrow screen goodies</pre>
1200 <pre> with forbidden attribute (bug 3202)
1202 <pre width="8" onmouseover="alert(document.cookie)">Narrow screen goodies</pre>
1204 <pre width="8">Narrow screen goodies</pre>
1209 Entities inside <pre>
1218 <pre> with forbidden attribute values (bug 3202)
1220 <pre width="8" style="border-width: expression(alert(document.cookie))">Narrow screen goodies</pre>
1222 <pre width="8" style="/* insecure input */">Narrow screen goodies</pre>
1227 <nowiki> inside <pre> (bug 13238)
1235 <pre><nowiki><nowiki></nowiki>Foo<nowiki></nowiki></nowiki></pre>
1243 <pre><nowiki>Foo</nowiki></pre>
1248 <nowiki> and <pre> preference (first one wins)
1279 </pre> inside nowiki
1281 <nowiki></pre></nowiki>
1288 Templates: Indent-Pre: 1a. Templates that break a line should suppress <pre>
1296 Templates: Indent-Pre: 1b. Templates that break a line should suppress <pre>
1306 Templates: Indent-Pre: 1c: Wrapping should be based on expanded content
1318 Templates: Indent-Pre: 1d: Wrapping should be based on expanded content
1339 Templates: Indent-Pre: 1e. Wrapping should be based on expanded content
1343 {{echo| foo}}{{echo| bar}}
1348 {{echo|<!--cmt--> foo}}
1350 <!--cmt-->{{echo| foo}}
1352 {{echo|{{echo| }}bar}}
1370 Templates: Indent-Pre: 1f: Wrapping should be based on expanded content
1407 Templates: Single-line variant of parameter whitespace stripping test
1413 {{echo|{{echo| a}}}}
1415 {{echo|1={{echo| a}}}}
1428 Templates: Strip whitespace from named parameters, but not positional ones
1456 ### Parsoid-centric tests for testing RT edge cases for pre
1460 1a. Indent-Pre and Comments
1473 1b. Indent-Pre and Comments
1486 1c. Indent-Pre and Comments
1499 2a. Indent-Pre and tables
1520 2b. Indent-Pre and tables
1536 2c. Indent-Pre and tables (bug 42252)
1553 3a. Indent-Pre and block tags (single-line html)
1561 <pre><span> foo </span>
1566 3b. Indent-Pre and block tags (pre-content on separate line)
1618 4. Multiple spaces at start-of-line
1637 5. White-space in indent-pre
1638 NOTE: the white-space char on 2nd line is significant
1651 ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric)
1655 HTML-pre: 1. embedded newlines
1691 HTML-pre: 2: indented text
1704 HTML-pre: 3: other wikitext
1725 ### Definition lists
1732 <dl><dt> name </dt><dd> Definition
1738 Definition list for indentation only
1742 <dl><dd> Indented text
1748 Definition list with no space
1752 <dl><dt>name</dt><dd>Definition
1758 Definition list with URL link
1760 ; http://example.com/ : definition
1762 <dl><dt> <a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> </dt><dd> definition
1768 Definition list with bracketed URL link
1770 ;[http://www.example.com/ Example]:Something about it
1772 <dl><dt><a rel="nofollow" class="external text" href="http://www.example.com/">Example</a></dt><dd>Something about it
1778 Definition list with wikilink containing colon
1780 ; [[Help:FAQ]]: The least-read page on Wikipedia
1782 <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
1787 # At Brion's and JeLuF's insistence... :)
1789 Definition list with news link containing colon
1791 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
1793 <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!
1799 Malformed definition list with colon
1801 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
1803 <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
1809 Definition lists: colon in external link text
1811 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
1813 <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
1819 Definition lists: colon in HTML attribute
1821 ;<b style="display: inline">bold</b>
1823 <dl><dt><b style="display: inline">bold</b>
1829 Definition lists: self-closed tag
1831 ;one<br/>two : two-line fun
1833 <dl><dt>one<br />two </dt><dd> two-line fun
1839 Bug 11748: Literal closing tags
1843 <dd>test test test test test</dd>
1845 <dd>test test test test test</dd>
1850 <dd>test test test test test</dd>
1852 <dd>test test test test test</dd>
1858 Definition and unordered list using wiki syntax nested in unordered list using html tags.
1861 ; term : description
1867 <dl><dt> term </dt><dd> description
1878 Definition list with empty definition and following paragraph
1883 <dl><dt> term</dt><dd>
1890 Nested definition lists using html syntax
1907 Definition Lists: No nesting: Multiple dd's
1921 Definition Lists: Indentation: Regular
1937 Definition Lists: Indentation: Missing 1st level
1951 Definition Lists: Indentation: Multi-level indent
1955 <dl><dd><dl><dd><dl><dd>i3
1963 Definition Lists: Hacky use to indent tables
1970 should be left alone
1972 <dl><dd><dl><dd><table>
1977 </td></tr></table></dd></dl></dd></dl>
1979 should be left alone
1982 ## The PHP parser treats : items (dd) without a corresponding ; item (dt)
1983 ## as an empty dt item. It also ignores all but the last ";" when followed
1984 ## by ":" later on. So, ";" are not ignored in ";;;t3" but are ignored in
1985 ## ";;;t3 :d1". So, PHP parser behavior is a little inconsistent wrt multiple
1988 ## Ex: ";;t2 ::d2" is transformed into:
2000 ## But, Parsoid treats "; :" as a tight atomic unit and excess ":" as plain text
2001 ## So, the same wikitext above (;;t2 ::d2) is transformed into:
2012 ## All Parsoid only definition list tests have this difference.
2014 ## See also: https://bugzilla.wikimedia.org/show_bug.cgi?id=6569
2015 ## and http://lists.wikimedia.org/pipermail/wikitext-l/2011-November/000483.html
2018 Table / list interaction: indented table with lists in table contents
2040 </td></tr></table></dd></dl>
2045 Table / list interaction: lists nested in tables nested in indented lists
2070 </td></tr></table></dd></dl>
2078 Definition Lists: Nesting: Multi-level (Parsoid only)
2108 Definition Lists: Nesting: Test 2 (Parsoid only)
2128 Definition Lists: Nesting: Test 3 (Parsoid only)
2156 Definition Lists: Nesting: Test 4
2161 <dl><dd><dl><dd><dl><dt>t3
2171 Definition Lists: Mixed Lists: Test 1
2177 <dl><dd><dl><dt><ul><li> foo
2189 Definition Lists: Mixed Lists: Test 2
2203 Definition Lists: Mixed Lists: Test 3
2208 <ul><li><dl><dd><dl><dd><dl><dd> d1
2219 Definition Lists: Mixed Lists: Test 4
2224 <ul><li><dl><dt>d1 </dt><dd>d2
2225 </dd><dt>d3 </dt><dd>d4
2233 Definition Lists: Mixed Lists: Test 5
2248 Definition Lists: Mixed Lists: Test 6
2253 <ol><li><ul><li><dl><dd>d1
2265 Definition Lists: Mixed Lists: Test 7
2279 Definition Lists: Mixed Lists: Test 8
2295 Definition Lists: Mixed Lists: Test 9
2299 <ul><li><dl><dt>foo </dt><dd>bar
2307 Definition Lists: Mixed Lists: Test 10
2311 <ul><li><ol><li><dl><dt>foo </dt><dd>bar
2320 Definition Lists: Mixed Lists: Test 11
2325 <ul><li><ol><li><ul><li><ol><li><dl><dt>foo </dt><dd><ul><li><dl><dt><dl><dt>bar
2330 <dl><dt>boo </dt><dd>baz
2341 Definition Lists: Weird Ones: Test 1
2343 *#;*::;; foo : bar (who uses this?)
2345 <ul><li><ol><li><dl><dt> foo </dt><dd><ul><li><dl><dd><dl><dd><dl><dt><dl><dt> bar (who uses this?)
2361 External links: non-bracketed
2363 Non-bracketed: http://example.com
2365 <p>Non-bracketed: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
2370 External links: numbered
2372 Numbered: [http://example.com]
2373 Numbered: [http://example.net]
2374 Numbered: [http://example.com]
2376 <p>Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[1]</a>
2377 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.net">[2]</a>
2378 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[3]</a>
2383 External links: specified text
2385 Specified text: [http://example.com link]
2387 <p>Specified text: <a rel="nofollow" class="external text" href="http://example.com">link</a>
2392 External links: trail
2394 Linktrails should not work for external links: [http://example.com link]s
2396 <p>Linktrails should not work for external links: <a rel="nofollow" class="external text" href="http://example.com">link</a>s
2401 External links: dollar sign in URL
2403 http://example.com/1$2345
2405 <p><a rel="nofollow" class="external free" href="http://example.com/1$2345">http://example.com/1$2345</a>
2410 External links: dollar sign in URL (named)
2412 [http://example.com/1$2345]
2414 <p><a rel="nofollow" class="external autonumber" href="http://example.com/1$2345">[1]</a>
2419 External links: open square bracket forbidden in URL (bug 4377)
2421 http://example.com/1[2345
2423 <p><a rel="nofollow" class="external free" href="http://example.com/1">http://example.com/1</a>[2345
2428 External links: open square bracket forbidden in URL (named) (bug 4377)
2430 [http://example.com/1[2345]
2432 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
2437 External links: nowiki in URL link text (bug 6230)
2439 [http://example.com/ <nowiki>''example site''</nowiki>]
2441 <p><a rel="nofollow" class="external text" href="http://example.com/">''example site''</a>
2446 External links: newline forbidden in text (bug 6230 regression check)
2448 [http://example.com/ first
2451 <p>[<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> first
2457 External links: Pipe char between url and text
2459 [http://example.com | link]
2461 <p><a rel="nofollow" class="external text" href="http://example.com">| link</a>
2466 External links: protocol-relative URL in brackets
2468 [//example.com/ Test]
2470 <p><a rel="nofollow" class="external text" href="//example.com/">Test</a>
2475 External links: protocol-relative URL in brackets without text
2479 <p><a rel="nofollow" class="external autonumber" href="//example.com">[1]</a>
2484 External links: protocol-relative URL in free text is left alone
2488 <p>//example.com/Foo
2493 External links: protocol-relative URL in the middle of a word is left alone (bug 30269)
2495 foo//example.com/Foo
2497 <p>foo//example.com/Foo
2504 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2506 <p>External image: <img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
2511 External image from https
2513 External image from https: https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2515 <p>External image from https: <img src="https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
2520 Link to non-http image, no img tag
2522 Link to non-http image, no img tag: ftp://example.com/test.jpg
2524 <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>
2529 External links: terminating separator
2531 Terminating separator: http://example.com/thing,
2533 <p>Terminating separator: <a rel="nofollow" class="external free" href="http://example.com/thing">http://example.com/thing</a>,
2538 External links: intervening separator
2540 Intervening separator: http://example.com/1,2,3
2542 <p>Intervening separator: <a rel="nofollow" class="external free" href="http://example.com/1,2,3">http://example.com/1,2,3</a>
2547 External links: old bug with URL in query
2549 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
2551 <p>Old bug with URL in query: <a rel="nofollow" class="external text" href="http://example.com/thing?url=http://example.com">link</a>
2556 External links: old URL-in-URL bug, mixed protocols
2558 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
2560 <p>And again with mixed protocols: <a rel="nofollow" class="external text" href="ftp://example.com?url=http://example.com">link</a>
2565 External links: URL in text
2567 URL in text: [http://example.com http://example.com]
2569 <p>URL in text: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
2574 External links: Clickable images
2576 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
2578 <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>
2583 External links: raw ampersand
2585 Old & use: http://x&y
2587 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
2592 External links: encoded ampersand
2594 Old & use: http://x&y
2596 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
2601 External links: encoded equals (bug 6102)
2603 http://example.com/?foo=bar
2605 <p><a rel="nofollow" class="external free" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a>
2610 External links: [raw ampersand]
2612 Old & use: [http://x&y]
2614 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
2619 External links: [encoded ampersand]
2621 Old & use: [http://x&y]
2623 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
2628 External links: [encoded equals] (bug 6102)
2630 [http://example.com/?foo=bar]
2632 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
2637 External links: [IDN ignored character reference in hostname; strip it right off]
2639 [http://e‌xample.com/]
2641 <p><a rel="nofollow" class="external autonumber" href="http://example.com/">[1]</a>
2645 # FIXME: This test (the IDN characters in the text of a link) is an inconsistency.
2646 # Where an external link could easily circumvent the sanitization of the text of
2647 # a link like this (where an IDN-ignore character is in the URL somewhere), this
2648 # test demands a higher standard. That's a bit strange.
2652 # http://example.com -> [http://example.com|http://example.com]
2653 # [http://example.com|http://example.com] -> [http://example.com|http://example.com]
2655 # The first example is sanitized, but the second is not. Any security benefits
2656 # from this production are trivial to circumvent. Either remove this test and
2657 # let the parser(s) do their thing unaccosted, or fix the inconsistency and change
2658 # the test accordingly.
2663 External links: IDN ignored character reference in hostname; strip it right off
2665 http://e‌xample.com/
2667 <p><a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>
2672 External links: www.jpeg.org (bug 554)
2676 <p><a rel="nofollow" class="external free" href="http://www.jpeg.org">http://www.jpeg.org</a>
2681 External links: URL within URL (original bug 2)
2683 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
2685 <p><a rel="nofollow" class="external autonumber" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp">[1]</a>
2690 BUG 361: URL inside bracketed URL
2692 [http://www.example.com/foo http://www.example.com/bar]
2694 <p><a rel="nofollow" class="external text" href="http://www.example.com/foo">http://www.example.com/bar</a>
2699 BUG 361: URL within URL, not bracketed
2701 http://www.example.com/foo?=http://www.example.com/bar
2703 <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>
2708 BUG 289: ">"-token in URL-tail
2710 http://www.example.com/<hello>
2712 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><hello>
2717 BUG 289: literal ">"-token in URL-tail
2719 http://www.example.com/<b>html</b>
2721 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><b>html</b>
2726 BUG 289: ">"-token in bracketed URL
2728 [http://www.example.com/<hello> stuff]
2730 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><hello> stuff</a>
2735 BUG 289: literal ">"-token in bracketed URL
2737 [http://www.example.com/<b>html</b> stuff]
2739 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><b>html</b> stuff</a>
2744 BUG 289: literal double quote at end of URL
2746 http://www.example.com/"hello"
2748 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a>"hello"
2753 BUG 289: literal double quote in bracketed URL
2755 [http://www.example.com/"hello" stuff]
2757 <p><a rel="nofollow" class="external text" href="http://www.example.com/">"hello" stuff</a>
2762 External links: multiple legal whitespace is fine, Magnus. Don't break it please. (bug 5081)
2764 [http://www.example.com test]
2766 <p><a rel="nofollow" class="external text" href="http://www.example.com">test</a>
2771 External links: link text with spaces
2773 [http://www.example.com a b c]
2774 [http://www.example.com ''a'' ''b'']
2776 <p><a rel="nofollow" class="external text" href="http://www.example.com">a b c</a>
2777 <a rel="nofollow" class="external text" href="http://www.example.com"><i>a</i> <i>b</i></a>
2782 External links: wiki links within external link (Bug 3695)
2784 [http://example.com [[wikilink]] embedded in ext link]
2786 <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>
2791 BUG 787: Links with one slash after the url protocol are invalid
2795 [http:/example.com title]
2797 <p>http:/example.com
2798 </p><p>[http:/example.com title]
2803 Bracketed external links with template-generated invalid target
2805 [{{echo|http:/example.com}} title]
2807 <p>[http:/example.com title]
2812 Bug 2702: Mismatched <i>, <b> and <a> tags are invalid
2814 ''[http://example.com text'']
2815 [http://example.com '''text]'''
2816 ''Something [http://example.com in italic'']
2817 ''Something [http://example.com mixed''''', even bold]'''
2818 '''''Now [http://example.com both''''']
2820 <p><a rel="nofollow" class="external text" href="http://example.com"><i>text</i></a>
2821 <a rel="nofollow" class="external text" href="http://example.com"><b>text</b></a>
2822 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>in italic</i></a>
2823 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>mixed</i><b>, even bold</b></a>
2824 <i><b>Now </b></i><a rel="nofollow" class="external text" href="http://example.com"><i><b>both</b></i></a>
2830 Bug 4781: %26 in URL
2832 http://www.example.com/?title=AT%26T
2834 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a>
2838 # According to http://dev.w3.org/html5/spec/Overview.html#parsing-urls a plain
2839 # % is actually legal in HTML5. Any change in output would need testing though.
2841 Bug 4781, 5267: %25 in URL
2843 http://www.example.com/?title=100%25_Bran
2845 <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>
2850 Bug 4781, 5267: %28, %29 in URL
2852 http://www.example.com/?title=Ben-Hur_%281959_film%29
2854 <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>
2860 Bug 4781: %26 in autonumber URL
2862 [http://www.example.com/?title=AT%26T]
2864 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=AT%26T">[1]</a>
2869 Bug 4781, 5267: %26 in autonumber URL
2871 [http://www.example.com/?title=100%25_Bran]
2873 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=100%25_Bran">[1]</a>
2878 Bug 4781, 5267: %28, %29 in autonumber URL
2880 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
2882 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">[1]</a>
2888 Bug 4781: %26 in bracketed URL
2890 [http://www.example.com/?title=AT%26T link]
2892 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=AT%26T">link</a>
2897 Bug 4781, 5267: %26 in bracketed URL
2899 [http://www.example.com/?title=100%25_Bran link]
2901 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=100%25_Bran">link</a>
2906 Bug 4781, 5267: %28, %29 in bracketed URL
2908 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
2910 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a>
2915 External link containing double-single-quotes in text '' (bug 4598 sanity check)
2917 Some [http://example.com/ pretty ''italics'' and stuff]!
2919 <p>Some <a rel="nofollow" class="external text" href="http://example.com/">pretty <i>italics</i> and stuff</a>!
2924 External link containing double-single-quotes in text embedded in italics (bug 4598 sanity check)
2926 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
2928 <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>
2933 External link containing double-single-quotes with no space separating the url from text in italics
2935 [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]].]
2937 <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>
2942 URL-encoding in URL functions (single parameter)
2944 {{localurl:Some page|amp=&}}
2946 <p>/index.php?title=Some_page&amp=&
2951 URL-encoding in URL functions (multiple parameters)
2953 {{localurl:Some page|q=?&=&}}
2955 <p>/index.php?title=Some_page&q=?&amp=&
2962 http://example.com/index.php?foozoid%5B%5D=bar
2964 http://example.com/index.php?foozoid[]=bar
2966 <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>
2967 </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>
2972 IPv6 urls (bug 21261)
2976 http://[2404:130:0:1000::187:2]/index.php
2978 <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>
2983 Non-extlinks in brackets
2992 [{{echo|foo}} ''bar'']
2993 [{{echo|foo}}l's] errand
2994 [{{echo|foo}}l's errand]
2996 [url=http://example.com]
3009 [url=<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>]
3020 Normal text. '''Bold text.''' Normal text. ''Italic text.''
3022 Normal text. '''''Bold italic text.''''' Normal text.
3024 <p>Normal text. <b>Bold text.</b> Normal text. <i>Italic text.</i>
3025 </p><p>Normal text. <i><b>Bold italic text.</b></i> Normal text.
3031 Unclosed and unmatched quotes (php)
3035 '''''Bold italic text '''with bold deactivated''' in between.'''''
3037 '''''Bold italic text ''with italic deactivated'' in between.'''''
3041 ..spanning two paragraphs (should not work).'''
3043 '''Bold tag left open
3045 ''Italic tag left open
3049 <!-- Unmatching number of opening, closing tags: -->
3050 '''This year''''s election ''should'' beat '''last year''''s.
3052 ''Tom'''s car is bigger than ''Susan'''s.
3054 Plain ''italic'''s plain
3056 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
3057 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
3058 </p><p><b>Bold text..</b>
3059 </p><p>..spanning two paragraphs (should not work).
3060 </p><p><b>Bold tag left open</b>
3061 </p><p><i>Italic tag left open</i>
3063 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
3064 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
3065 </p><p>Plain <i>italic'</i>s plain
3068 # Parsoid inserts an empty bold tag pair at the end of the line, that the PHP
3069 # parser strips. The wikitext contains just the first half of the bold
3070 # quote pair. (There's also a case where Parsoid nests <b> and <i>
3071 # differently than the PHP parser.)
3073 Unclosed and unmatched quotes (parsoid)
3077 '''''Bold italic text '''with bold deactivated''' in between.'''''
3079 '''''Bold italic text ''with italic deactivated'' in between.'''''
3083 ..spanning two paragraphs (should not work).'''
3085 '''Bold tag left open
3087 ''Italic tag left open
3091 <!-- Unmatching number of opening, closing tags: -->
3092 '''This year''''s election ''should'' beat '''last year''''s.
3094 ''Tom'''s car is bigger than ''Susan'''s.
3096 Plain ''italic'''s plain
3098 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
3099 </p><p><i><b>Bold italic text </b></i><b>with italic deactivated<i> in between.</i></b>
3100 </p><p><b>Bold text..</b>
3101 </p><p>..spanning two paragraphs (should not work).<b></b>
3102 </p><p><b>Bold tag left open</b>
3103 </p><p><i>Italic tag left open</i>
3105 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
3106 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
3107 </p><p>Plain <i>italic'</i>s plain
3114 ### some content taken from http://meta.wikimedia.org/wiki/MediaWiki_User%27s_Guide:_Using_tables
3117 # This should not produce <table></table> as <table><tr><td></td></tr></table>
3118 # is the bare minimun required by the spec, see:
3119 # http://www.w3.org/TR/xhtml-modularization/dtd_module_defs.html#a_module_Basic_Tables
3121 A table with no data.
3127 # A table with nothing but a caption is invalid XHTML, we might want to render
3128 # this as <p>caption</p>
3130 A table with nothing but a caption
3138 </caption><tr><td></td></tr></table>
3143 A table with caption with default-spaced attributes and a table row
3146 |+ style="color: red;" | caption1
3152 <caption style="color: red;"> caption1
3161 A table with captions with non-default spaced attributes and a table row
3164 |+style="color: red;"|caption2
3165 |+ style="color: red;"| caption3
3171 <caption style="color: red;">caption2
3173 <caption style="color: red;"> caption3
3182 Table td-cell syntax variations
3186 | foo bar foo || baz
3187 | style='color:red;' | baz
3188 | style='color:red;' || baz
3195 <td> foo bar foo </td>
3198 <td style="color:red;"> baz
3200 <td> style='color:red;' </td>
3228 Simple table but with multiple dashes for row wikitext
3246 Multiplication table
3248 {| border="1" cellpadding="2"
3249 |+Multiplication table
3251 ! × !! 1 !! 2 !! 3
3269 <table border="1" cellpadding="2">
3270 <caption>Multiplication table
3317 Accept "||" in table headings
3332 Accept "||" in indented table headings
3342 </th></tr></table></dd></dl>
3347 Accept empty attributes in td/th cells (td/th cells starting with leading ||)
3364 Accept "| !" at start of line in tables (ignore !-attribute)
3368 | !style="color:red" | bar
3380 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 +/-
3384 |style='color:red;'|+1
3385 |style='color:blue;'|-1
3397 <td style="color:red;">+1
3399 <td style="color:blue;">-1
3423 |rowspan=2| Cell 2, row 1 (and 2)
3434 <td rowspan="2"> Cell 2, row 1 (and 2)
3452 {| bgcolor=#ABCDEF border=2
3457 |the original table again
3465 <table bgcolor="#ABCDEF" border="2">
3473 <td>the original table again
3479 Invalid attributes in table cell (bug 1830)
3494 Table security: embedded pipes (http://lists.wikimedia.org/mailman/htdig/wikitech-l/2006-April/022293.html)
3497 | |[ftp://|x||]" onmouseover="alert(document.cookie)">test
3501 <td>[<a rel="nofollow" class="external free" href="ftp://%7Cx">ftp://%7Cx</a></td>
3502 <td>]" onmouseover="alert(document.cookie)">test
3511 Indented table markup mixed with indented pre content (proposed in bug 6200)
3516 Text that should be rendered preformatted
3524 <pre>Text that should be rendered preformatted
3533 Template-generated table cell attributes and cell content
3541 <td style="color: red"> Foo
3547 Table with row followed by newlines and table heading
3565 Table with empty line following the start tag
3582 # FIXME: Preserve the attribute properly (with an empty string as value) in
3583 # the PHP parser. Parsoid implements the behavior below.
3585 Table attributes with empty value
3601 Wikitext table with a lot of comments
3624 Wikitext table with double-line table cell
3641 Table cell with a single comment
3657 # The expected HTML structure in this test is debatable. The PHP parser does
3658 # not parse this kind of table at all. The main focus for Parsoid is on
3659 # round-tripping, so this output is ok for now. TODO: revisit!
3661 Wikitext table with html-syntax row (Parsoid)
3674 <td>foo</td></tr></tbody></table>
3681 Plain link, capitalized
3685 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
3690 Plain link, uncapitalized
3694 <p><a href="/wiki/Main_Page" title="Main Page">main Page</a>
3701 [[Main Page|The Main Page]]
3703 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
3712 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig</a>
3717 Broken link with fragment
3719 [[Zigzagzogzagzig#zug]]
3721 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig#zug</a>
3726 Special page link with fragment
3728 [[Special:Version#anchor]]
3730 <p><a href="/wiki/Special:Version#anchor" title="Special:Version">Special:Version#anchor</a>
3735 Nonexistent special page link with fragment
3737 [[Special:ThisNameWillHopefullyNeverBeUsed#anchor]]
3739 <p><a href="/wiki/Special:ThisNameWillHopefullyNeverBeUsed" class="new" title="Special:ThisNameWillHopefullyNeverBeUsed (page does not exist)">Special:ThisNameWillHopefullyNeverBeUsed#anchor</a>
3746 xxx[[main Page]], xxx[[Main Page]], Xxx[[main Page]] XXX[[main Page]], XXX[[Main Page]]
3748 <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>
3755 [[Main Page]]xxx, [[Main Page]]XXX, [[Main Page]]!!!
3757 <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>!!!
3768 Bug 43661: Piped links with identical prefixes
3770 [[prefixed article|prefixed articles with spaces]]
3772 [[prefixed article|prefixed articlesaoeu]]
3774 [[Main Page|Main Page test]]
3776 <p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articles with spaces</a>
3777 </p><p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articlesaoeu</a>
3778 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page test</a>
3784 Link with HTML entity in suffix / tail
3786 [[Main Page]]", [[Main Page]]a
3788 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>", <a href="/wiki/Main_Page" title="Main Page">Main Page</a>a
3793 Link with 3 brackets
3802 Piped link with 3 brackets
3804 [[[main page|the main page]]]
3806 <p>[[[main page|the main page]]]
3811 Link with multiple pipes
3813 [[Main Page|The|Main|Page]]
3815 <p><a href="/wiki/Main_Page" title="Main Page">The|Main|Page</a>
3822 [[Talk:Parser testing]], [[Meta:Disclaimers]]
3824 <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>
3829 Piped link to namespace
3831 [[Meta:Disclaimers|The disclaimers]]
3833 <p><a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">The disclaimers</a>
3840 [[Usually caused by a typo (oops}]]
3842 <p>[[Usually caused by a typo (oops}]]
3847 Link containing % (not as a hex sequence)
3851 <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>
3856 Link containing % as a single hex sequence interpreted to char
3860 <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>
3865 Link containing % as a double hex sequence interpreted to hex sequence
3869 <p>[[7%2525 Solution]]
3874 Link containing "#<" and "#>" % as a hex sequences- these are valid section anchors
3875 Example for such a section: == < ==
3877 [[%23%3c]][[%23%3e]]
3879 <p><a href="#.3C">#<</a><a href="#.3E">#></a>
3884 Link containing "<#" and ">#" as a hex sequences
3886 [[%3c%23]][[%3e%23]]
3888 <p>[[%3c%23]][[%3e%23]]
3893 Link containing double-single-quotes '' (bug 4598)
3895 [[Lista d''e paise d''o munno]]
3897 <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>
3902 Link containing double-single-quotes '' in text (bug 4598 sanity check)
3904 Some [[Link|pretty ''italics'' and stuff]]!
3906 <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>!
3911 Link containing double-single-quotes '' in text embedded in italics (bug 4598 sanity check)
3913 ''Some [[Link|pretty ''italics'' and stuff]]!
3915 <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>
3920 Link with double quotes in title part (literal) and alternate part (interpreted)
3922 [[File:Denys Savchenko ''Pentecoste''.jpg]]
3926 [[''Pentecoste''|Pentecoste]]
3928 [[''Pentecoste''|''Pentecoste'']]
3930 <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>
3931 </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>
3932 </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>
3933 </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>
3938 Broken image links with HTML captions (bug 39700)
3940 [[File:Nonexistent|<script></script>]]
3941 [[File:Nonexistent|100px|<script></script>]]
3942 [[File:Nonexistent|<]]
3943 [[File:Nonexistent|a<i>b</i>c]]
3945 <p><a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
3946 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
3947 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><</a>
3948 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent">abc</a>
3955 [[http://www.example.com]]
3957 <p>[<a rel="nofollow" class="external autonumber" href="http://www.example.com">[1]</a>]
3962 Plain link to URL with link text
3964 [[http://www.example.com Link text]]
3966 <p>[<a rel="nofollow" class="external text" href="http://www.example.com">Link text</a>]
3971 Plain link to protocol-relative URL
3973 [[//www.example.com]]
3975 <p>[<a rel="nofollow" class="external autonumber" href="//www.example.com">[1]</a>]
3980 Plain link to protocol-relative URL with link text
3982 [[//www.example.com Link text]]
3984 <p>[<a rel="nofollow" class="external text" href="//www.example.com">Link text</a>]
3989 Plain link to page with question mark in title
3995 <p><a href="/wiki/A%3Fb" title="A?b">A?b</a>
3996 </p><p><a href="/wiki/A%3Fb" title="A?b">Baz</a>
4001 # I'm fairly sure the expected result here is wrong.
4002 # We want these to be URL links, not pseudo-pages with URLs for titles....
4003 # However the current output is also pretty screwy.
4006 # I'm changing it to match the current output--it arguably makes more
4007 # sense in the light of the test above. Old expected result was:
4008 #<p>Piped link to URL: <a href="/index.php?title=Http://www.example.com&action=edit" class="new">an example URL</a>
4010 # But I think this test is bordering on "garbage in, garbage out" anyway.
4015 Piped link to URL: [[http://www.example.com|an example URL]]
4017 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
4022 BUG 2: [[page|http://url/]] should link to page, not http://url/
4024 [[Main Page|http://url/]]
4026 <p><a href="/wiki/Main_Page" title="Main Page">http://url/</a>
4031 BUG 337: Escaped self-links should be bold
4035 [[Bug462]] [[Bug462]]
4037 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong>
4042 Self-link to section should not be bold
4046 [[Main Page#section]]
4048 <p><a href="/wiki/Main_Page#section" title="Main Page">Main Page#section</a>
4059 Self-link to numeric title
4065 <p><strong class="selflink">0</strong>
4070 Link to numeric-equivalent title
4076 <p><a href="/wiki/00" title="00">00</a>
4081 <nowiki> inside a link
4083 [[Main<nowiki> Page</nowiki>]] [[Main Page|the main page <nowiki>[it's not very good]</nowiki>]]
4085 <p>[[Main Page]] <a href="/wiki/Main_Page" title="Main Page">the main page [it's not very good]</a>
4090 Non-breaking spaces in title
4092 [[ Main Page ]]
4094 <p><a href="/wiki/Main_Page" title="Main Page">  Main   Page  </a>
4099 Internal link with ca linktrail, surrounded by bold apostrophes (bug 27473 primary issue)
4105 <p><b><a href="/wiki/Main_Page" title="Main Page">Main Page</a></b>
4110 Internal link with ca linktrail, surrounded by italic apostrophes (bug 27473 primary issue)
4116 <p><i><a href="/wiki/Main_Page" title="Main Page">Main Page</a></i>
4121 Internal link with en linktrail: no apostrophes (bug 27473)
4127 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (page does not exist)">Something</a>'nice
4132 Internal link with ca linktrail with apostrophes (bug 27473)
4138 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (encara no existeix)">Something'nice</a>
4143 Internal link with kaa linktrail with apostrophes (bug 27473)
4149 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (bet ele jaratılmag'an)">Something'nice</a>
4154 Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
4162 [http://wp.org ''foo'']
4164 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> bar</a>
4165 </p><p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> <i>bar</i></a>
4166 </p><p><a rel="nofollow" class="external text" href="http://wp.org">foo</a>
4167 </p><p><a rel="nofollow" class="external text" href="http://wp.org"><i>foo</i></a>
4172 ### Interwiki links (see maintenance/interwiki.sql)
4176 Inline interwiki link
4178 [[MeatBall:SoftSecurity]]
4180 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a>
4185 Inline interwiki link with empty title (bug 2372)
4189 <p><a href="http://www.usemod.com/cgi-bin/mb.pl" class="extiw" title="meatball:">MeatBall:</a>
4194 Interwiki link encoding conversion (bug 1636)
4196 *[[Wikipedia:ro:Olteniţa]]
4197 *[[Wikipedia:ro:Olteniţa]]
4199 <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>
4200 </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>
4206 Interwiki link with fragment (bug 2130)
4208 [[MeatBall:SoftSecurity#foo]]
4210 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity#foo" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity#foo</a>
4225 Double interlanguage link
4236 Interlanguage link, with prefix links
4248 Double interlanguage link, with prefix links (bug 8897)
4261 Parsoid-specific test: Wikilinks with should RT properly
4267 <p><a href="/index.php?title=WW_II&action=edit&redlink=1" class="new" title="WW II (lonkásá ezalí tɛ̂)">WW II</a>
4285 Broken br tag sanitization
4294 Incorrecly removing closing slashes from correctly formed XHTML
4296 <br style="clear:both;" />
4298 <p><br style="clear:both;" />
4303 Failing to transform badly formed HTML into correct XHTML
4305 <br style="clear: left;">
4306 <br style="clear: right;">
4307 <br style="clear: both;">
4309 <p><br style="clear: left;" />
4310 <br style="clear: right;" />
4311 <br style="clear: both;" />
4316 Handling html with a div self-closing tag
4325 <p><div title />
4329 <p><div title=bar />
4330 <div title=bar/>
4332 <div title="bar/"></div>
4338 Handling html with a br self-closing tag
4347 <p><br title="title" />
4348 <br title="title" />
4357 Horizontal ruler (should it add that extra space?)
4371 Horizontal ruler -- 4+ dashes render hr
4380 Horizontal ruler -- eats additional dashes on the same line
4389 Horizontal ruler -- does not collaps dashes on consecutive lines
4400 Horizontal ruler -- <4 dashes render as plain text
4409 Horizontal ruler -- Supports content following dashes on same line
4418 ### Block-level elements
4441 <ol><li>Numbered list
4458 ***#Number on level 4
4460 **#Number on level 3
4461 **#Number on level 3
4465 #** Level 3, but ordered
4468 <ol><li> with numbers
4470 <ul><li> and bullets
4472 <ol><li> and numbers
4474 </li><li>bullets again
4475 <ul><li>bullet level 2
4476 <ul><li>bullet level 3
4477 <ol><li>Number on level 4
4480 </li><li>bullet level 2
4481 <ol><li>Number on level 3
4482 </li><li>Number on level 3
4485 <ol><li>number level 2
4488 <ul><li><ul><li> Level 3
4492 <ol><li><ul><li><ul><li> Level 3, but ordered
4526 Nested lists 3 (first element empty)
4539 Nested lists 4 (first element empty)
4552 Nested lists 5 (both elements empty)
4565 Nested lists 6 (both elements empty)
4578 Nested lists 7 (skip initial nesting levels)
4582 <ul><li><ul><li><ul><li> foo
4590 Nested lists 8 (multiple nesting transitions)
4598 <ul><li><ul><li> bar
4608 1. Lists with start-of-line-transparent tokens before bullets: Comments
4622 2. Lists with start-of-line-transparent tokens before bullets: Template close
4634 Unbalanced closing block tags break a list
4635 (Disabled since php parser generates broken html -- relies on Tidy to fix up)
4645 </li></ul></div><div>
4651 Unbalanced closing non-block tags don't break a list
4652 (Disabled since php parser generates broken html -- relies on Tidy to fix up)
4662 <ul><li>a<span></span>
4668 Unclosed formatting tags that straddle lists are closed and reopened
4669 (Disabled since php parser generates broken html -- relies on Tidy to fix up)
4677 </li><li> <s> b </s>
4682 List embedded in a non-block tag
4683 (Ugly Parsoid output -- worth fixing; Disabled for PHP parser since it relies on Tidy)
4691 <p><small></small></p>
4697 <p><small></small></p>
4701 List items are not parsed correctly following a <pre> block (bug 785)
4707 <ul><li> <pre>foo</pre>
4708 </li><li> <pre>bar</pre>
4715 List items from template
4726 * notSOL{{inner list}}
4745 List interrupted by empty line or heading
4755 <ul><li><ul><li> bar
4758 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: A heading">edit</a>]</span> <span class="mw-headline" id="A_heading">A heading</span></h2>
4759 <ul><li> Another list item
4765 Multiple list tags generated by templates
4780 Single-comment whitespace lines dont break lists, but multi-comment whitespace lines do
4783 <!--This line will NOT split the list-->
4785 <!--This line will NOT split the list either-->
4787 <!--foo--> <!--This line with more than 1 comment will split the list-->
4804 Magic Word: {{CURRENTDAY}}
4813 Magic Word: {{CURRENTDAY2}}
4822 Magic Word: {{CURRENTDAYNAME}}
4831 Magic Word: {{CURRENTDOW}}
4840 Magic Word: {{CURRENTMONTH}}
4849 Magic Word: {{CURRENTMONTHABBREV}}
4851 {{CURRENTMONTHABBREV}}
4858 Magic Word: {{CURRENTMONTHNAME}}
4860 {{CURRENTMONTHNAME}}
4867 Magic Word: {{CURRENTMONTHNAMEGEN}}
4869 {{CURRENTMONTHNAMEGEN}}
4876 Magic Word: {{CURRENTTIME}}
4885 Magic Word: {{CURRENTWEEK}} (@bug 4594)
4894 Magic Word: {{CURRENTYEAR}}
4903 Magic Word: {{FULLPAGENAME}}
4905 title=[[User:Ævar Arnfjörð Bjarmason]]
4909 <p>User:Ævar Arnfjörð Bjarmason
4914 Magic Word: {{FULLPAGENAMEE}}
4916 title=[[User:Ævar Arnfjörð Bjarmason]]
4920 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
4925 Magic Word: {{NAMESPACE}}
4927 title=[[User:Ævar Arnfjörð Bjarmason]]
4936 Magic Word: {{NAMESPACEE}}
4938 title=[[User:Ævar Arnfjörð Bjarmason]]
4947 Magic Word: {{NAMESPACENUMBER}}
4949 title=[[User:Ævar Arnfjörð Bjarmason]]
4958 Magic Word: {{NUMBEROFFILES}}
4967 Magic Word: {{PAGENAME}}
4969 title=[[User:Ævar Arnfjörð Bjarmason]]
4973 <p>Ævar Arnfjörð Bjarmason
4978 Magic Word: {{PAGENAME}} with metacharacters
4980 title=[['foo & bar = baz']]
4984 <p><i>'foo & bar = baz'</i>
4989 Magic Word: {{PAGENAME}} with metacharacters (bug 26781)
4991 title=[[*RFC 1234 http://example.com/]]
4995 <p>*RFC 1234 http://example.com/
5000 Magic Word: {{PAGENAMEE}}
5002 title=[[User:Ævar Arnfjörð Bjarmason]]
5006 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
5011 Magic Word: {{PAGENAMEE}} with metacharacters (bug 26781)
5013 title=[[*RFC 1234 http://example.com/]]
5017 <p>*RFC_1234_http://example.com/
5022 Magic Word: {{REVISIONID}}
5031 Magic Word: {{SCRIPTPATH}}
5040 Magic Word: {{SERVER}}
5044 <p><a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
5049 Magic Word: {{SERVERNAME}}
5058 Magic Word: {{SITENAME}}
5067 Case-sensitive magic words, when cased differently, should just be template transclusions
5074 <p><a href="/index.php?title=Template:CurrentMonth&action=edit&redlink=1" class="new" title="Template:CurrentMonth (page does not exist)">Template:CurrentMonth</a>
5075 <a href="/index.php?title=Template:Currentday&action=edit&redlink=1" class="new" title="Template:Currentday (page does not exist)">Template:Currentday</a>
5076 <a href="/index.php?title=Template:CURreNTweEK&action=edit&redlink=1" class="new" title="Template:CURreNTweEK (page does not exist)">Template:CURreNTweEK</a>
5077 <a href="/index.php?title=Template:CurrentHour&action=edit&redlink=1" class="new" title="Template:CurrentHour (page does not exist)">Template:CurrentHour</a>
5082 Case-insensitive magic words should still work with weird casing.
5092 <a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
5097 Namespace 1 {{ns:1}}
5106 Namespace 1 {{ns:01}}
5115 Namespace 0 {{ns:0}} (bug 4783)
5123 Namespace 0 {{ns:00}} (bug 4783)
5131 Namespace -1 {{ns:-1}}
5140 Namespace User {{ns:User}}
5149 Namespace User talk {{ns:User_talk}}
5158 Namespace User talk {{ns:uSeR tAlK}}
5167 Namespace File {{ns:File}}
5176 Namespace File {{ns:Image}}
5185 Namespace (lang=de) Benutzer {{ns:User}}
5196 Namespace (lang=de) Benutzer Diskussion {{ns:3}}
5202 <p>Benutzer Diskussion
5210 {{urlencode:hi world?!}}
5211 {{urlencode:hi world?!|WIKI}}
5212 {{urlencode:hi world?!|PATH}}
5213 {{urlencode:hi world?!|QUERY}}
5226 Magic links: internal link to RFC (bug 479)
5230 <p><a href="/index.php?title=RFC_123&action=edit&redlink=1" class="new" title="RFC 123 (page does not exist)">RFC 123</a>
5235 Magic links: RFC (bug 479)
5239 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
5244 Magic links: ISBN (bug 1937)
5248 <p><a href="/wiki/Special:BookSources/0306406152" class="internal mw-magiclink-isbn">ISBN 0-306-40615-2</a>
5253 Magic links: PMID incorrectly converts space to underscore
5257 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
5266 Nonexistent template
5268 {{thistemplatedoesnotexist}}
5270 <p><a href="/index.php?title=Template:Thistemplatedoesnotexist&action=edit&redlink=1" class="new" title="Template:Thistemplatedoesnotexist (page does not exist)">Template:Thistemplatedoesnotexist</a>
5275 Template with invalid target containing tags
5277 {{a<b>b</b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
5279 <p>{{a<b>b</b>|foo|a=b|a = b}}
5284 Template with invalid target containing unclosed tag
5286 {{a<b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
5288 <p>{{a<b>|foo|a=b|a = b}}</b>
5295 This is a test template
5303 <p>This is a test template
5308 Template with explicit namespace
5312 <p>This is a test template
5320 This is a test template with parameter {{{param}}}
5326 {{paramtest|param=foo}}
5328 <p>This is a test template with parameter foo
5333 Template:paramtestnum
5339 Template unnamed parameter
5341 {{paramtestnum|Main Page|the main page}}
5343 <p><a href="/wiki/Main_Page" title="Main Page">the main page</a>
5348 Template:templatesimple
5354 Template:templateredirect
5356 #redirect [[Template:templatesimple]]
5360 Template:templateasargtestnum
5366 Template:templateasargtest
5368 {{template{{{templ}}}}}
5372 Template:templateasargtest2
5378 Template with template name as unnamed argument
5380 {{templateasargtestnum|templatesimple}}
5387 Template with template name as argument
5389 {{templateasargtest|templ=simple}}
5396 Template with template name as argument (2)
5398 {{templateasargtest2|templ=templatesimple}}
5405 Template:templateasargtestdefault
5407 {{{{{templ|templatesimple}}}}}
5417 Template with default value
5419 {{templateasargtestdefault}}
5426 Template with default value (value set)
5428 {{templateasargtestdefault|templ=templa}}
5437 {{templateredirect}}
5444 Template with argument in separate line
5446 {{ templateasargtest |
5454 Template with complex template as argument
5457 param ={{ templateasargtest |
5460 <p>This is a test template with parameter (test)
5465 Template with thumb image (with link in description)
5468 param =[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]}}
5470 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>
5475 Template:complextemplate
5477 {{{1}}} {{paramtest|
5478 param ={{{param}}}}}
5482 Template with complex arguments
5485 param ={{ templateasargtest |
5486 templ = simple }}|[[Template:complextemplate|link]]}}
5488 <p><a href="/wiki/Template:Complextemplate" title="Template:Complextemplate">link</a> This is a test template with parameter (test)
5493 BUG 553: link with two variables in a piped link
5496 |[[{{{1}}}|{{{2}}}]]
5501 <td>[[{{{1}}}|{{{2}}}]]
5507 Magic variable as template parameter
5509 {{paramtest|param={{SITENAME}}}}
5511 <p>This is a test template with parameter MediaWiki
5518 [[{{{param}}}|link]]
5522 Template parameter as link source
5524 {{linktest|param=Main Page}}
5526 <p><a href="/wiki/Main_Page" title="Main Page">link</a>
5531 Template-generated attribute string (k='v')
5533 <span {{attr_str|id|v1}}>bar</span>
5535 <p><span id="v1">bar</span>
5542 including another template, {{paramtest|param={{{arg}}}}}
5546 Template passing argument to another template
5548 {{paramtest2|arg='hmm'}}
5550 <p>including another template, This is a test template with parameter 'hmm'
5561 Template as link source
5565 [[{{linktest2}}|Main Page]]
5567 [[{{linktest2}}]]Page
5569 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
5570 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
5571 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>Page
5589 Template infinite loop
5593 <p><span class="error">Template loop detected: <a href="/wiki/Template:Loop1" title="Template:Loop1">Template:Loop1</a></span>
5598 Template from main namespace
5617 BUG 529: Template with table, not included at beginning of line
5636 BUG 523: Template shouldn't eat newline (or add an extra one before table)
5656 BUG 41: Template parameters shown as broken links
5665 Template with targets containing wikilinks
5669 {{[[{{echo|foo}}]]}}
5671 {{{{echo|[[foo}}]]}}
5673 <p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
5674 </p><p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
5682 ''None'' of '''this''' should be
5684 but rather passed unmodified
5688 # hmm, fix this or just deprecate msgnw and document its behavior?
5694 {{msgnw:MSGNW test}}
5696 <p>''None'' of '''this''' should be
5698 but rather passed unmodified
5706 {{int:youhavenewmessages|lots of money|not!}}
5708 <p>You have lots of money (not!).
5715 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
5719 <includeonly> and <noinclude> being included
5730 <onlyinclude>Foo</onlyinclude>bar
5734 <onlyinclude> being included
5746 <onlyinclude>Foo</onlyinclude>bar<includeonly>zar</includeonly>
5750 <onlyinclude> and <includeonly> being included
5759 <includeonly> and <noinclude> on a page
5761 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
5768 Un-closed <noinclude>
5775 <onlyinclude> on a page
5777 <onlyinclude>Foo</onlyinclude>bar
5784 Un-closed <onlyinclude>
5791 Self-closed noinclude, includeonly, onlyinclude tags
5802 Unbalanced includeonly and noinclude tags
5806 |b</noinclude></noinclude>
5807 |c</noinclude></includeonly>
5808 |d</includeonly></includeonly>
5817 <td>c</includeonly>
5819 <td>d</includeonly></includeonly>
5825 Template:Includeonly section
5828 ==Includeonly section==
5834 Bug 6563: Edit link generation for section shown by <includeonly>
5836 {{includeonly section}}
5838 <h2><span class="editsection">[<a href="/index.php?title=Template:Includeonly_section&action=edit&section=T-1" title="Template:Includeonly section">edit</a>]</span> <span class="mw-headline" id="Includeonly_section">Includeonly section</span></h2>
5839 <h2><span class="editsection">[<a href="/index.php?title=Template:Includeonly_section&action=edit&section=T-2" title="Template:Includeonly section">edit</a>]</span> <span class="mw-headline" id="Section_T-1">Section T-1</span></h2>
5843 # Uses same input as the contents of [[Template:Includeonly section]]
5845 Bug 6563: Section extraction for section shown by <includeonly>
5850 ==Includeonly section==
5858 Bug 6563: Edit link generation for section suppressed by <includeonly>
5861 ==Includeonly section==
5865 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section 1">edit</a>]</span> <span class="mw-headline" id="Section_1">Section 1</span></h2>
5870 Bug 6563: Section extraction for section suppressed by <includeonly>
5875 ==Includeonly section==
5883 Un-closed <includeonly>
5890 ### <includeonly> and <noinclude> in attributes
5893 0. includeonly around the entire attribute
5895 <span <includeonly>id="v1"</includeonly><noinclude>id="v2"</noinclude>>bar</span>
5897 <p><span id="v2">bar</span>
5902 1. includeonly in html attr key
5904 <span <noinclude>id</noinclude><includeonly>about</includeonly>="foo">bar</span>
5906 <p><span id="foo">bar</span>
5911 2. includeonly in html attr value
5913 <span id="<noinclude>v1</noinclude><includeonly>v2</includeonly>">bar</span>
5914 <span id=<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>>bar</span>
5916 <p><span id="v1">bar</span>
5917 <span id="v1">bar</span>
5922 3. includeonly in part of an attr value
5924 <span style="color:<noinclude>red</noinclude><includeonly>blue</includeonly>;">bar</span>
5926 <p><span style="color:red;">bar</span>
5931 ### Testing parsing of templates where a template arg
5932 ### has the same name as the template itself.
5942 Templates: Template Name/Arg clash: 1. Use of positional param
5951 Templates: Template Name/Arg clash: 2. Use of named param
5960 Templates: Template Name/Arg clash: 3. Use of named param with empty input
5969 ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged
5973 Templates: 1. Simple use
5982 Templates: 2. Inside a block tag
5984 <div>{{echo|Foo}}</div>
5991 Templates: P-wrapping: 1a. Templates on consecutive lines
6002 Templates: P-wrapping: 1b. Templates on consecutive lines
6016 Templates: P-wrapping: 1c. Templates on consecutive lines
6019 {{echo|bar}} <div>baz</div>
6028 Templates: Inline Text: 1. Multiple tmeplate uses
6030 {{echo|Foo}}bar{{echo|baz}}
6037 Templates: Inline Text: 2. Back-to-back template uses
6039 {{echo|Foo}}{{echo|bar}}
6046 Templates: Block Tags: 1. Multiple template uses
6048 {{echo|<div>Foo</div>}}<div>bar</div>{{echo|<div>baz</div>}}
6050 <div>Foo</div><div>bar</div><div>baz</div>
6055 Templates: Block Tags: 2. Back-to-back template uses
6057 {{echo|<div>Foo</div>}}{{echo|<div>bar</div>}}
6059 <div>Foo</div><div>bar</div>
6064 Templates: Links: 1. Simple example
6066 {{echo|[[Foo|bar]]}}
6068 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
6073 Templates: Links: 2. Generation of link href
6075 [[{{echo|Foo}}|bar]]
6077 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
6082 Templates: Links: 3. Generation of part of a link href
6084 [[Fo{{echo|o}}|bar]]
6088 [[Foo{{echo|bar}}baz]]
6090 [[Foo{{echo|bar}}|bar]]
6092 [[:Foo{{echo|bar}}]]
6094 [[:Foo{{echo|bar}}|bar]]
6096 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
6097 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
6098 </p><p><a href="/index.php?title=Foobarbaz&action=edit&redlink=1" class="new" title="Foobarbaz (page does not exist)">Foobarbaz</a>
6099 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
6100 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
6101 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
6106 Templates: Links: 4. Multiple templates generating link href
6108 [[{{echo|F}}{{echo|o}}ob{{echo|ar}}]]
6110 <p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
6115 Templates: Links: 5. Generation of link text
6117 [[Foo|{{echo|bar}}]]
6119 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
6124 Templates: Links: 5. Nested templates (only outermost template should be marked)
6126 {{echo|[[{{echo|Foo}}|bar]]}}
6128 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
6133 Templates: HTML Tag: 1. Generation of HTML attr. key
6135 <div {{echo|style}}="color:red;">foo</div>
6137 <div style="color:red;">foo</div>
6142 Templates: HTML Tag: 2. Generation of HTML attr. value
6144 <div style={{echo|'color:red;'}}>foo</div>
6146 <div style="color:red;">foo</div>
6151 Templates: HTML Tag: 3. Generation of HTML attr key and value
6153 <div {{echo|style}}={{echo|'color:red;'}}>foo</div>
6155 <div style="color:red;">foo</div>
6160 Templates: HTML Tag: 4. Generation of starting piece of HTML attr value
6162 <div title="{{echo|This is a long title}} with just one piece templated">foo</div>
6164 <div title="This is a long title with just one piece templated">foo</div>
6169 Templates: HTML Tag: 5. Generation of middle piece of HTML attr value
6171 <div title="This is a long title with just {{echo|one piece}} templated">foo</div>
6173 <div title="This is a long title with just one piece templated">foo</div>
6178 Templates: HTML Tag: 6. Generation of end piece of HTML attr value
6180 <div title="This is a long title with just one piece {{echo|templated}}">foo</div>
6182 <div title="This is a long title with just one piece templated">foo</div>
6187 Templates: HTML Tag: 7. Generation of partial attribute key string
6189 <div st{{echo|yle}}="color:red;">foo</div>
6191 <div style="color:red;">foo</div>
6196 Templates: HTML Tables: 1. Generating start of a HTML table
6198 {{echo|<table><tr><td>foo</td>}}</tr></table>
6200 <table><tr><td>foo</td></tr></table>
6205 Templates: HTML Tables: 2a. Generating middle of a HTML table
6207 <table><tr>{{echo|<td>foo</td>}}</tr></table>
6209 <table><tr><td>foo</td></tr></table>
6214 Templates: HTML Tables: 2b. Generating middle of a HTML table
6216 <table>{{echo|<tr><td>foo</td></tr>}}</table>
6218 <table><tr><td>foo</td></tr></table>
6223 Templates: HTML Tables: 3. Generating end of a HTML table
6225 <table><tr>{{echo|<td>foo</td></tr></table>}}
6227 <table><tr><td>foo</td></tr></table>
6232 Templates: HTML Tables: 4a. Generating a single tag of a HTML table
6234 {{echo|<table>}}<tr><td>foo</td></tr></table>
6236 <table><tr><td>foo</td></tr></table>
6241 Templates: HTML Tables: 4b. Generating a single tag of a HTML table
6243 <table>{{echo|<tr>}}<td>foo</td></tr></table>
6245 <table><tr><td>foo</td></tr></table>
6250 Templates: HTML Tables: 4c. Generating a single tag of a HTML table
6252 <table><tr>{{echo|<td>}}foo</td></tr></table>
6254 <table><tr><td>foo</td></tr></table>
6259 Templates: HTML Tables: 4d. Generating a single tag of a HTML table
6261 <table><tr><td>foo{{echo|</td>}}</tr></table>
6263 <table><tr><td>foo</td></tr></table>
6268 Templates: HTML Tables: 4e. Generating a single tag of a HTML table
6270 <table><tr><td>foo</td>{{echo|</tr>}}</table>
6272 <table><tr><td>foo</td></tr></table>
6277 Templates: HTML Tables: 4f. Generating a single tag of a HTML table
6279 <table><tr><td>foo</td></tr>{{echo|</table>}}
6281 <table><tr><td>foo</td></tr></table>
6286 Templates: Wiki Tables: 1a. Fostering of entire template content
6294 <tr><td></td></tr></table>
6299 Templates: Wiki Tables: 1b. Fostering of entire template content
6312 <tr><td></td></tr></table>
6317 Templates: Wiki Tables: 2. Fostering of partial template content
6327 <tr><td></td></tr></table>
6332 Templates: Wiki Tables: 3. td-content via multiple templates
6335 {{echo|{{pipe}}a}}{{echo|b}}
6346 Templates: Wiki Tables: 4. Templated tags, no content
6352 <tr><td></td></tr></table>
6357 Templates: Wiki Tables: 5. Templated tags, regular td-tags
6371 Templates: Wiki Tables: 6. Templated tags, templated td-tags
6385 Templates: Lists: Multi-line list-items via templates
6387 *{{echo|a {{nonexistent|
6389 *{{echo|b {{nonexistent|
6392 <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>
6393 </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>
6399 Templates: Ugly nesting: 1. Quotes opened/closed across templates (echo)
6401 {{echo|''a}}{{echo|b''c''d}}{{echo|''e}}
6403 <p><i>ab</i>c<i>d</i>e
6408 Templates: Ugly nesting: 2. Quotes opened/closed across templates (echo_with_span)
6409 (PHP parser generates misnested html)
6413 {{echo_with_span|''a}}{{echo_with_span|b''c''d}}{{echo_with_span|''e}}
6415 <p><span><i>a</i></span><i><span>b</span></i><span>c</span><i>d</i><span>e</span></p>
6419 Templates: Ugly nesting: 3. Quotes opened/closed across templates (echo_with_div)
6420 (PHP parser generates misnested html)
6424 {{echo_with_div|''a}}{{echo_with_div|b''c''d}}{{echo_with_div|''e}}
6427 <div><i>b</i>c<i>d</i></div>
6432 Templates: Ugly nesting: 4. Divs opened/closed across templates
6434 a<div>b{{echo|c</div>d}}e
6441 Templates: Ugly templates: 1. Navbox template parses badly leading to table misnesting
6447 |{{echo|foo</table>}}
6451 <table about="#mwt1" typeof="mw:Object/Template ">
6452 <tbody><tr><td>foo</td></tr></tbody></table><span about="#mwt1">
6453 bar</span><span about="#mwt1">
6458 Templates: Ugly templates: 2. Navbox template parses badly leading to table misnesting
6468 <td>1. {{echo|foo </table>}}</td>
6470 <td>2. {{echo|baz </table>}}</td>
6483 <table about="#mwt1" typeof="mw:Object/Template">
6488 <td >1. foo </td></tr></tbody></table></td>
6490 <td >2. baz </td></tr></tbody></table><span about="#mwt1">
6491 </span><span about="#mwt1">
6493 abc</span><span about="#mwt1">
6494 </span><span about="#mwt1">
6495 </span><span about="#mwt1">
6496 </span><span about="#mwt1">
6497 </span><span about="#mwt1">
6499 xyz</span><span about="#mwt1">
6500 </span><span about="#mwt1">
6505 Templates: Ugly templates: 3. newline-only template parameter
6514 # This looks like a bug: a single newline triggers p/br for some reason.
6516 Templates: Ugly templates: 4. newline-only template parameter inconsistency
6527 Parser Functions: 1. Simple example
6536 Parser Functions: 2. Nested use (only outermost should be marked up)
6545 ### Pre-save transform tests
6548 pre-save transform: subst:
6554 This is a test template
6558 pre-save transform: normal template
6568 pre-save transform: nonexistent template
6572 {{thistemplatedoesnotexist}}
6574 {{thistemplatedoesnotexist}}
6579 pre-save transform: subst magic variables
6588 # This is bug 89, which I fixed. -- wtm
6590 pre-save transform: subst: templates with parameters
6594 {{subst:paramtest|param="something else"}}
6596 This is a test template with parameter "something else"
6602 <nowiki>'''not wiki'''</nowiki>
6606 pre-save transform: nowiki in subst (bug 1188)
6610 {{subst:nowikitest}}
6612 <nowiki>'''not wiki'''</nowiki>
6617 Template:commenttest
6619 This template has <!-- a comment --> in it.
6623 pre-save transform: comment in subst (bug 1936)
6627 {{subst:commenttest}}
6629 This template has <!-- a comment --> in it.
6633 pre-save transform: unclosed tag
6637 <nowiki>'''not wiki'''
6639 <nowiki>'''not wiki'''
6643 pre-save transform: mixed tag case
6647 <NOwiki>'''not wiki'''</noWIKI>
6649 <NOwiki>'''not wiki'''</noWIKI>
6653 pre-save transform: unclosed comment in <nowiki>
6657 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
6659 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
6665 <span onmouseover="alert('crap')">Oh no</span>
6669 (confirming safety of fix for subst bug 1936)
6671 {{Template:dangerous}}
6673 <p><span>Oh no</span>
6678 pre-save transform: comment containing gallery (bug 5024)
6682 <!-- <gallery>data</gallery> -->
6684 <!-- <gallery>data</gallery> -->
6688 pre-save transform: comment containing extension
6692 <!-- <tag>data</tag> -->
6694 <!-- <tag>data</tag> -->
6698 pre-save transform: comment containing nowiki
6702 <!-- <nowiki>data</nowiki> -->
6704 <!-- <nowiki>data</nowiki> -->
6708 pre-save transform: <noinclude> in subst (bug 3298)
6718 pre-save transform: <onlyinclude> in subst (bug 3298)
6730 {{<includeonly>subst:</includeonly>Includes}}
6734 Template:SafeSubstTest
6736 {{<includeonly>safesubst:</includeonly>Includes}}
6740 bug 22297: safesubst: works during PST
6744 {{subst:SafeSubstTest}}{{safesubst:SubstTest}}
6750 bug 22297: safesubst: works during normal parse
6759 subst: does not work during normal parse
6763 <p>{{subst:Includes}}
6768 pre-save transform: context links ("pipe trick")
6772 [[Article (context)|]]
6775 [[Bar:Article (context)|]]
6776 [[:Bar:Article (context)|]]
6778 [[|Article (context)]]
6782 [[Article (context)|Article]]
6783 [[Bar:Article|Article]]
6784 [[:Bar:Article|Article]]
6785 [[Bar:Article (context)|Article]]
6786 [[:Bar:Article (context)|Article]]
6788 [[Article (context)]]
6789 [[Bar:X (Y) Z|X (Y) Z]]
6790 [[:Bar:X (Y) Z|X (Y) Z]]
6794 pre-save transform: context links ("pipe trick") with interwiki prefix
6798 [[interwiki:Article|]]
6799 [[:interwiki:Article|]]
6800 [[interwiki:Bar:Article|]]
6801 [[:interwiki:Bar:Article|]]
6803 [[interwiki:Article|Article]]
6804 [[:interwiki:Article|Article]]
6805 [[interwiki:Bar:Article|Bar:Article]]
6806 [[:interwiki:Bar:Article|Bar:Article]]
6810 pre-save transform: context links ("pipe trick") with parens in title
6812 pst title=[[Somearticle (context)]]
6816 [[Article (context)|Article]]
6820 pre-save transform: context links ("pipe trick") with comma in title
6822 pst title=[[Someplace, Somewhere]]
6825 [[Otherplace, Elsewhere|]]
6826 [[Otherplace, Elsewhere, Anywhere|]]
6828 [[Otherplace, Somewhere|Otherplace]]
6829 [[Otherplace, Elsewhere|Otherplace]]
6830 [[Otherplace, Elsewhere, Anywhere|Otherplace]]
6834 pre-save transform: context links ("pipe trick") with parens and comma
6836 pst title=[[Someplace (IGNORED), Somewhere]]
6839 [[Otherplace (place), Elsewhere|]]
6841 [[Otherplace, Somewhere|Otherplace]]
6842 [[Otherplace (place), Elsewhere|Otherplace]]
6846 pre-save transform: context links ("pipe trick") with comma and parens
6848 pst title=[[Who, me? (context)]]
6851 [[Me, Myself, and I (1937 song)|]]
6853 [[Yes, you. (context)|Yes, you.]]
6854 [[Me, Myself, and I (1937 song)|Me, Myself, and I]]
6858 pre-save transform: context links ("pipe trick") with namespace
6860 pst title=[[Ns:Somearticle]]
6864 [[Ns:Article|Article]]
6868 pre-save transform: context links ("pipe trick") with namespace and parens
6870 pst title=[[Ns:Somearticle (context)]]
6874 [[Ns:Article (context)|Article]]
6878 pre-save transform: context links ("pipe trick") with namespace and comma
6880 pst title=[[Ns:Somearticle, Context, Whatever]]
6884 [[Ns:Article, Context, Whatever|Article]]
6888 pre-save transform: context links ("pipe trick") with namespace, comma and parens
6890 pst title=[[Ns:Somearticle, Context (context)]]
6894 [[Ns:Article (context)|Article]]
6898 pre-save transform: context links ("pipe trick") with namespace, parens and comma
6900 pst title=[[Ns:Somearticle (IGNORED), Context]]
6904 [[Ns:Article, Context|Article]]
6908 pre-save transform: context links ("pipe trick") with full-width parens and no space (Japanese and Chinese style, bug 30149)
6912 [[Article(context)|]]
6913 [[Bar:Article(context)|]]
6914 [[:Bar:Article(context)|]]
6915 [[|Article(context)]]
6919 [[Article(context)|Article]]
6920 [[Bar:Article(context)|Article]]
6921 [[:Bar:Article(context)|Article]]
6922 [[Article(context)]]
6924 [[:Bar:X(Y)Z|X(Y)Z]]
6928 pre-save transform: context links ("pipe trick") with full-width parens and space (Japanese and Chinese style, bug 30149)
6932 [[Article (context)|]]
6933 [[Bar:Article (context)|]]
6934 [[:Bar:Article (context)|]]
6935 [[|Article (context)]]
6939 [[Article (context)|Article]]
6940 [[Bar:Article (context)|Article]]
6941 [[:Bar:Article (context)|Article]]
6942 [[Article (context)]]
6943 [[Bar:X (Y) Z|X (Y) Z]]
6944 [[:Bar:X (Y) Z|X (Y) Z]]
6948 pre-save transform: context links ("pipe trick") with parens and no space (Korean style, bug 30149)
6952 [[Article(context)|]]
6953 [[Bar:Article(context)|]]
6954 [[:Bar:Article(context)|]]
6955 [[|Article(context)]]
6959 [[Article(context)|Article]]
6960 [[Bar:Article(context)|Article]]
6961 [[:Bar:Article(context)|Article]]
6962 [[Article(context)]]
6964 [[:Bar:X(Y)Z|X(Y)Z]]
6968 pre-save transform: context links ("pipe trick") with commas (bug 21660)
6972 [[Article (context), context|]]
6973 [[Article (context),context|]]
6974 [[Bar:Article (context), context|]]
6975 [[Bar:Article (context),context|]]
6976 [[:Bar:Article (context), context|]]
6977 [[:Bar:Article (context),context|]]
6979 [[Article (context), context|Article]]
6980 [[Article (context),context|Article]]
6981 [[Bar:Article (context), context|Article]]
6982 [[Bar:Article (context),context|Article]]
6983 [[:Bar:Article (context), context|Article]]
6984 [[:Bar:Article (context),context|Article]]
6988 pre-save transform: trim trailing empty lines
6992 Empty lines are trimmed
6998 Empty lines are trimmed
7002 pre-save transform: Signature expansion
7007 * <noinclude>~~~</noinclude>
7008 * <includeonly>~~~</includeonly>
7009 * <onlyinclude>~~~</onlyinclude>
7011 * [[Special:Contributions/127.0.0.1|127.0.0.1]]
7012 * <noinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</noinclude>
7013 * <includeonly>[[Special:Contributions/127.0.0.1|127.0.0.1]]</includeonly>
7014 * <onlyinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</onlyinclude>
7019 pre-save transform: Signature expansion in nowiki tags (bug 93)
7025 <nowiki>~~~~</nowiki>
7027 <includeonly><nowiki>~~~~</nowiki></includeonly>
7029 <noinclude><nowiki>~~~~</nowiki></noinclude>
7031 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
7033 {{subst:Foo}} shall be converted to FOO
7035 As well as inside noinclude/onlyinclude
7036 <noinclude>{{subst:Foo}}</noinclude>
7037 <onlyinclude>{{subst:Foo}}</onlyinclude>
7039 But not inside includeonly
7040 <includeonly>{{subst:Foo}}</includeonly>
7044 <nowiki>~~~~</nowiki>
7046 <includeonly><nowiki>~~~~</nowiki></includeonly>
7048 <noinclude><nowiki>~~~~</nowiki></noinclude>
7050 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
7052 FOO shall be converted to FOO
7054 As well as inside noinclude/onlyinclude
7055 <noinclude>FOO</noinclude>
7056 <onlyinclude>FOO</onlyinclude>
7058 But not inside includeonly
7059 <includeonly>{{subst:Foo}}</includeonly>
7063 ### Message transform tests
7066 message transform: magic variables
7076 message transform: should not transform wiki markup
7086 message transform: <noinclude> in transcluded template (bug 4926)
7096 message transform: <onlyinclude> in transcluded template (bug 4926)
7106 {{#special:}} page name, known
7110 {{#special:Recentchanges}}
7112 Special:RecentChanges
7116 {{#special:}} page name with subpage, known
7120 {{#special:Recentchanges/param}}
7122 Special:RecentChanges/param
7126 {{#special:}} page name, unknown
7130 {{#special:foobarnonexistent}}
7132 No such special page
7136 {{#speciale:}} page name, known
7140 {{#speciale:Recentchanges}}
7142 Special:RecentChanges
7146 {{#speciale:}} page name with subpage, known
7150 {{#speciale:Recentchanges/param}}
7152 Special:RecentChanges/param
7156 {{#speciale:}} page name, unknown
7160 {{#speciale:foobarnonexistent}}
7162 No_such_special_page
7171 [[Image:foobar.jpg]]
7173 <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>
7180 [[Image:foobar.jpg|right]]
7182 <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>
7187 Simple image (using File: namespace, now canonical)
7191 <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>
7198 [[Image:foobar.jpg|right|Caption text]]
7200 <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>
7205 Image with empty attribute
7207 [[Image:foobar.jpg|right||Caption text]]
7209 <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>
7214 Image with link tails
7216 123[[Image:foobar.jpg]]456
7217 123[[Image:foobar.jpg|right]]456
7218 123[[Image:foobar.jpg|thumb]]456
7220 <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
7222 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
7223 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
7228 Image with multiple captions -- only last one is accepted
7230 [[Image:foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
7232 <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>
7237 Image with width attribute at different positions
7239 [[Image:foobar.jpg|200px|right|Caption]]
7240 [[Image:foobar.jpg|right|200px|Caption]]
7241 [[Image:foobar.jpg|right|Caption|200px]]
7243 <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>
7244 <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>
7245 <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>
7250 Image with link parameter, wiki target
7252 [[Image:foobar.jpg|link=Target page]]
7254 <p><a href="/wiki/Target_page" title="Target page"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
7259 Image with link parameter, URL target
7261 [[Image:foobar.jpg|link=http://example.com/]]
7263 <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>
7268 Image with link parameter, wgExternalLinkTarget
7270 [[Image:foobar.jpg|link=http://example.com/]]
7272 wgExternalLinkTarget='foobar'
7274 <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>
7279 Image with link parameter, wgNoFollowLinks set to false
7281 [[Image:foobar.jpg|link=http://example.com/]]
7283 wgNoFollowLinks=false
7285 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
7290 Image with link parameter, wgNoFollowDomainExceptions
7292 [[Image:foobar.jpg|link=http://example.com/]]
7294 wgNoFollowDomainExceptions='example.com'
7296 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
7301 Image with link parameter, wgExternalLinkTarget, unnamed parameter
7303 [[Image:foobar.jpg|link=http://example.com/|Title]]
7305 wgExternalLinkTarget='foobar'
7307 <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>
7312 Image with empty link parameter
7314 [[Image:foobar.jpg|link=]]
7316 <p><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" />
7321 Image with link parameter (wiki target) and unnamed parameter
7323 [[Image:foobar.jpg|link=Target page|Title]]
7325 <p><a href="/wiki/Target_page" title="Title"><img alt="Title" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
7330 Image with link parameter (URL target) and unnamed parameter
7332 [[Image:foobar.jpg|link=http://example.com/|Title]]
7334 <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>
7339 Thumbnail image with link parameter
7343 [[Image:foobar.jpg|thumb|link=http://example.com/|Title]]
7345 <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>
7350 Manually-specified thumbnail image
7354 [[Image:Foobar.jpg|thumb=Thumb.png|Title]]
7356 <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>
7361 Manually-specified thumbnail image with explicit link to wiki page
7365 [[Image:Foobar.jpg|thumb=Thumb.png|link=Main Page|Title]]
7367 <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>
7372 Manually-specified thumbnail image with explicit link to url
7376 [[Image:Foobar.jpg|thumb=Thumb.png|link=http://example.com|Title]]
7378 <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>
7383 Manually-specified thumbnail image with explicit no link
7387 [[Image:Foobar.jpg|thumb=Thumb.png|link=|Title]]
7389 <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>
7394 Manually-specified thumbnail image with explicit link and alt text
7398 [[Image:Foobar.jpg|thumb=Thumb.png|link=Main Page|alt=alttext|Title]]
7400 <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>
7405 Image with frame and link
7407 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]]]
7409 <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>
7414 Image with frame and link and explicit alt
7416 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]|alt=Altitude]]
7418 <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>
7423 Image with wiki markup in implicit alt
7425 [[Image:Foobar.jpg|testing '''bold''' in alt]]
7427 <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>
7432 Image with wiki markup in explicit alt
7434 [[Image:Foobar.jpg|alt=testing '''bold''' in alt]]
7436 <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>
7441 Link to image page- image page normally doesn't exists, hence edit link
7442 Add test with existing image page
7443 #<p><a href="/wiki/File:Test" title="Image:Test">Image:test</a>
7447 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">Image:test</a>
7452 bug 18784 Link to non-existent image page with caption should use caption as link text
7454 [[:Image:test|caption]]
7456 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">caption</a>
7461 Frameless image caption with a free URL
7463 [[Image:foobar.jpg|http://example.com]]
7465 <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>
7470 Thumbnail image caption with a free URL
7472 [[Image:foobar.jpg|thumb|http://example.com]]
7474 <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>
7479 Thumbnail image caption with a free URL and explicit alt
7481 [[Image:foobar.jpg|thumb|http://example.com|alt=Alteration]]
7483 <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>
7488 BUG 1887: A ISBN with a thumbnail
7490 [[Image:foobar.jpg|thumb|ISBN 1235467890]]
7492 <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>
7497 BUG 1887: A RFC with a thumbnail
7499 [[Image:foobar.jpg|thumb|This is RFC 12354]]
7501 <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>
7506 BUG 1887: A mailto link with a thumbnail
7508 [[Image:foobar.jpg|thumb|Please mailto:nobody@example.com]]
7510 <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>
7514 # Pending resolution to bug 368
7516 BUG 648: Frameless image caption with a link
7518 [[Image:foobar.jpg|text with a [[link]] in it]]
7520 <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>
7525 BUG 648: Frameless image caption with a link (suffix)
7527 [[Image:foobar.jpg|text with a [[link]]foo in it]]
7529 <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>
7534 BUG 648: Frameless image caption with an interwiki link
7536 [[Image:foobar.jpg|text with a [[MeatBall:Link]] in it]]
7538 <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>
7543 BUG 648: Frameless image caption with a piped interwiki link
7545 [[Image:foobar.jpg|text with a [[MeatBall:Link|link]] in it]]
7547 <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>
7552 Escape HTML special chars in image alt text
7554 [[Image:foobar.jpg|& < > "]]
7556 <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>
7561 BUG 499: Alt text should have Ӓ, not &1234;
7563 [[Image:foobar.jpg|♀]]
7565 <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>
7570 Broken image caption with link
7572 [[Image:Foobar.jpg|thumb|This is a broken caption. But [[Main Page|this]] is just an ordinary link.
7574 <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.
7579 Image caption containing another image
7581 [[Image:Foobar.jpg|thumb|This is a caption with another [[Image:icon.png|image]] inside it!]]
7583 <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>
7588 Image caption containing a newline
7590 [[Image:Foobar.jpg|This
7593 <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>
7598 Parsoid: Image caption containing leading space
7599 (The leading space should not trigger nowiki escaping in wt2wt mode)
7601 [[Image:Foobar.jpg|thumb| bar]]
7603 <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>
7608 Bug 3090: External links other than http: in image captions
7610 [[Image:Foobar.jpg|thumb|200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
7612 <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>
7619 [[Image:foobar.jpg|a|class=b]]
7621 <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>
7626 Localized image handling (1).
7630 [[Archivo:Foobar.jpg|izquierda|enlace=foo|caption]]
7632 <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>
7637 Localized image handling (2).
7641 [[Archivo:Foobar.jpg|miniatura|izquierda|enlace=foo|caption]]
7643 <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>
7648 "border", "frameless" and "class" attributes on an image.
7650 [[File:Foobar.jpg|frameless|border|class=extra|caption]]
7652 <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>
7659 #REDIRECT [[File:Barfoo.jpg]]
7665 [[Image:Barfoo.jpg]]
7667 <p><a href="/wiki/File:Barfoo.jpg" title="File:Barfoo.jpg">File:Barfoo.jpg</a>
7672 Missing image with uploads disabled
7676 [[Image:Foobaz.jpg]]
7678 <p><a href="/wiki/File:Foobaz.jpg" title="File:Foobaz.jpg">File:Foobaz.jpg</a>
7687 Subpage test/subpage
7695 subpage title=[[Subpage test]]
7699 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a>
7704 Subpage noslash link
7706 subpage title=[[Subpage test]]
7710 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">subpage</a>
7719 <p><a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a>
7724 BUG 561: {{/Subpage}}
7726 subpage title=[[Page]]
7730 <p><a href="/index.php?title=Page/Subpage&action=edit&redlink=1" class="new" title="Page/Subpage (page does not exist)">Page/Subpage</a>
7738 Category:MediaWiki User's Guide
7746 [[:Category:MediaWiki User's Guide]]
7748 <p><a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">Category:MediaWiki User's Guide</a>
7757 [[Category:MediaWiki User's Guide]]
7759 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
7763 PAGESINCATEGORY invalid title fatal (r33546 fix)
7765 {{PAGESINCATEGORY:<bogus>}}
7772 Category with different sort key
7776 [[Category:MediaWiki User's Guide|Foo]]
7778 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
7782 Category with identical sort key
7786 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
7788 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
7792 Category with empty sort key
7797 [[Category:MediaWiki User's Guide|]]
7799 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
7803 Category with empty sort key and parentheses
7808 [[Category:Foo (bar)|]]
7810 [[Category:Foo (bar)|Foo]]
7814 Category with link tail
7819 123[[Category:Foo]]456
7821 123[[Category:Foo]]456
7825 Category with template
7830 [[Category:{{echo|Foo}}]]
7832 [[Category:{{echo|Foo}}]]
7836 Category with template in sort key
7841 [[Category:Foo|{{echo|Bar}}]]
7843 [[Category:Foo|{{echo|Bar}}]]
7847 Category with template in sort key and title
7852 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
7854 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
7858 Category / paragraph interactions
7860 Foo [[Category:Baz]] Bar
7862 Foo [[Category:Baz]]
7870 [[Category:Baz]] Bar
7883 {{echo|[[Category:Baz]]}}
7898 ### Inter-language links
7901 Inter-language links
7907 [[zh:食品]]
7909 es:Alimento fr:Nourriture zh:食品
7913 Duplicate interlanguage links (bug 24502)
7929 Basic section headings
7936 ===Smaller headline===
7939 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Headline 1">edit</a>]</span> <span class="mw-headline" id="Headline_1">Headline 1</span></h2>
7942 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Headline 2">edit</a>]</span> <span class="mw-headline" id="Headline_2">Headline 2</span></h2>
7945 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Smaller headline">edit</a>]</span> <span class="mw-headline" id="Smaller_headline">Smaller headline</span></h3>
7951 Section headings with TOC
7954 === Subheadline 1 ===
7955 ===== Skipping a level =====
7956 ====== Skipping a level ======
7960 ===Another headline===
7962 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
7964 <li class="toclevel-1 tocsection-1"><a href="#Headline_1"><span class="tocnumber">1</span> <span class="toctext">Headline 1</span></a>
7966 <li class="toclevel-2 tocsection-2"><a href="#Subheadline_1"><span class="tocnumber">1.1</span> <span class="toctext">Subheadline 1</span></a>
7968 <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>
7970 <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>
7977 <li class="toclevel-1 tocsection-5"><a href="#Headline_2"><span class="tocnumber">2</span> <span class="toctext">Headline 2</span></a>
7979 <li class="toclevel-2 tocsection-6"><a href="#Another_headline"><span class="tocnumber">2.1</span> <span class="toctext">Another headline</span></a></li>
7984 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Headline 1">edit</a>]</span> <span class="mw-headline" id="Headline_1">Headline 1</span></h2>
7985 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Subheadline 1">edit</a>]</span> <span class="mw-headline" id="Subheadline_1">Subheadline 1</span></h3>
7986 <h5><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Skipping a level">edit</a>]</span> <span class="mw-headline" id="Skipping_a_level">Skipping a level</span></h5>
7987 <h6><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Skipping a level">edit</a>]</span> <span class="mw-headline" id="Skipping_a_level_2">Skipping a level</span></h6>
7988 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Headline 2">edit</a>]</span> <span class="mw-headline" id="Headline_2">Headline 2</span></h2>
7991 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: Another headline">edit</a>]</span> <span class="mw-headline" id="Another_headline">Another headline</span></h3>
7995 # perl -e 'print "="x$_," Level $_ heading","="x$_,"\n" for 1..10'
7997 Handling of sections up to level 6 and beyond
8000 == Level 2 Heading==
8001 === Level 3 Heading===
8002 ==== Level 4 Heading====
8003 ===== Level 5 Heading=====
8004 ====== Level 6 Heading======
8005 ======= Level 7 Heading=======
8006 ======== Level 8 Heading========
8007 ========= Level 9 Heading=========
8008 ========== Level 10 Heading==========
8010 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
8012 <li class="toclevel-1 tocsection-1"><a href="#Level_1_Heading"><span class="tocnumber">1</span> <span class="toctext">Level 1 Heading</span></a>
8014 <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>
8016 <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>
8018 <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>
8020 <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>
8022 <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>
8023 <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>
8024 <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>
8025 <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>
8026 <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>
8039 <h1><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Level 1 Heading">edit</a>]</span> <span class="mw-headline" id="Level_1_Heading">Level 1 Heading</span></h1>
8040 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Level 2 Heading">edit</a>]</span> <span class="mw-headline" id="Level_2_Heading">Level 2 Heading</span></h2>
8041 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Level 3 Heading">edit</a>]</span> <span class="mw-headline" id="Level_3_Heading">Level 3 Heading</span></h3>
8042 <h4><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Level 4 Heading">edit</a>]</span> <span class="mw-headline" id="Level_4_Heading">Level 4 Heading</span></h4>
8043 <h5><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Level 5 Heading">edit</a>]</span> <span class="mw-headline" id="Level_5_Heading">Level 5 Heading</span></h5>
8044 <h6><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: Level 6 Heading">edit</a>]</span> <span class="mw-headline" id="Level_6_Heading">Level 6 Heading</span></h6>
8045 <h6><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=7" title="Edit section: = Level 7 Heading=">edit</a>]</span> <span class="mw-headline" id=".3D_Level_7_Heading.3D">= Level 7 Heading=</span></h6>
8046 <h6><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=8" title="Edit section: == Level 8 Heading==">edit</a>]</span> <span class="mw-headline" id=".3D.3D_Level_8_Heading.3D.3D">== Level 8 Heading==</span></h6>
8047 <h6><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=9" title="Edit section: === Level 9 Heading===">edit</a>]</span> <span class="mw-headline" id=".3D.3D.3D_Level_9_Heading.3D.3D.3D">=== Level 9 Heading===</span></h6>
8048 <h6><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=10" title="Edit section: ==== Level 10 Heading====">edit</a>]</span> <span class="mw-headline" id=".3D.3D.3D.3D_Level_10_Heading.3D.3D.3D.3D">==== Level 10 Heading====</span></h6>
8053 TOC regression (bug 9764)
8057 ==== title 1.1.1 ====
8062 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
8064 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
8066 <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>
8068 <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>
8071 <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>
8074 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
8076 <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>
8081 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: title 1">edit</a>]</span> <span class="mw-headline" id="title_1">title 1</span></h2>
8082 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: title 1.1">edit</a>]</span> <span class="mw-headline" id="title_1.1">title 1.1</span></h3>
8083 <h4><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: title 1.1.1">edit</a>]</span> <span class="mw-headline" id="title_1.1.1">title 1.1.1</span></h4>
8084 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: title 1.2">edit</a>]</span> <span class="mw-headline" id="title_1.2">title 1.2</span></h3>
8085 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: title 2">edit</a>]</span> <span class="mw-headline" id="title_2">title 2</span></h2>
8086 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: title 2.1">edit</a>]</span> <span class="mw-headline" id="title_2.1">title 2.1</span></h3>
8091 TOC with wgMaxTocLevel=3 (bug 6204)
8097 ==== title 1.1.1 ====
8102 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
8104 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
8106 <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>
8107 <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>
8110 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
8112 <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>
8117 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: title 1">edit</a>]</span> <span class="mw-headline" id="title_1">title 1</span></h2>
8118 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: title 1.1">edit</a>]</span> <span class="mw-headline" id="title_1.1">title 1.1</span></h3>
8119 <h4><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: title 1.1.1">edit</a>]</span> <span class="mw-headline" id="title_1.1.1">title 1.1.1</span></h4>
8120 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: title 1.2">edit</a>]</span> <span class="mw-headline" id="title_1.2">title 1.2</span></h3>
8121 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: title 2">edit</a>]</span> <span class="mw-headline" id="title_2">title 2</span></h2>
8122 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: title 2.1">edit</a>]</span> <span class="mw-headline" id="title_2.1">title 2.1</span></h3>
8127 TOC with wgMaxTocLevel=3 and two level four headings (bug 6204)
8133 ====Section 1.1.1====
8134 ====Section 1.1.1.1====
8137 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
8139 <li class="toclevel-1 tocsection-1"><a href="#Section_1"><span class="tocnumber">1</span> <span class="toctext">Section 1</span></a>
8141 <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>
8144 <li class="toclevel-1 tocsection-5"><a href="#Section_2"><span class="tocnumber">2</span> <span class="toctext">Section 2</span></a></li>
8147 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section 1">edit</a>]</span> <span class="mw-headline" id="Section_1">Section 1</span></h2>
8148 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Section 1.1">edit</a>]</span> <span class="mw-headline" id="Section_1.1">Section 1.1</span></h3>
8149 <h4><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: Section 1.1.1">edit</a>]</span> <span class="mw-headline" id="Section_1.1.1">Section 1.1.1</span></h4>
8150 <h4><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: Section 1.1.1.1">edit</a>]</span> <span class="mw-headline" id="Section_1.1.1.1">Section 1.1.1.1</span></h4>
8151 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: Section 2">edit</a>]</span> <span class="mw-headline" id="Section_2">Section 2</span></h2>
8157 Resolving duplicate section names
8162 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Foo bar">edit</a>]</span> <span class="mw-headline" id="Foo_bar">Foo bar</span></h2>
8163 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Foo bar">edit</a>]</span> <span class="mw-headline" id="Foo_bar_2">Foo bar</span></h2>
8168 Resolving duplicate section names with differing case (bug 10721)
8173 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Foo bar">edit</a>]</span> <span class="mw-headline" id="Foo_bar">Foo bar</span></h2>
8174 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Foo Bar">edit</a>]</span> <span class="mw-headline" id="Foo_Bar_2">Foo Bar</span></h2>
8186 Template with sections, __NOTOC__
8193 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section 0">edit</a>]</span> <span class="mw-headline" id="Section_0">Section 0</span></h2>
8194 <h3><span class="editsection">[<a href="/index.php?title=Template:Sections&action=edit&section=T-1" title="Template:Sections">edit</a>]</span> <span class="mw-headline" id="Section_1">Section 1</span></h3>
8195 <h2><span class="editsection">[<a href="/index.php?title=Template:Sections&action=edit&section=T-2" title="Template:Sections">edit</a>]</span> <span class="mw-headline" id="Section_2">Section 2</span></h2>
8196 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Section 4">edit</a>]</span> <span class="mw-headline" id="Section_4">Section 4</span></h2>
8201 __NOEDITSECTION__ keyword
8207 <h2> <span class="mw-headline" id="Section_1">Section 1</span></h2>
8208 <h2> <span class="mw-headline" id="Section_2">Section 2</span></h2>
8213 Link inside a section heading
8215 ==Section with a [[Main Page|link]] in it==
8217 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Section with a link in it">edit</a>]</span> <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></h2>
8222 TOC regression (bug 12077)
8229 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
8231 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
8233 <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>
8236 <li class="toclevel-1 tocsection-3"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a></li>
8239 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: title 1">edit</a>]</span> <span class="mw-headline" id="title_1">title 1</span></h2>
8240 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: title 1.1">edit</a>]</span> <span class="mw-headline" id="title_1.1">title 1.1</span></h3>
8241 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: title 2">edit</a>]</span> <span class="mw-headline" id="title_2">title 2</span></h2>
8246 BUG 1219 URL next to image (good)
8248 http://example.com [[Image:foobar.jpg]]
8250 <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>
8255 Short headings with trailing space should match behavior of Parser::doHeadings (bug 19910)
8258 The line above must have a trailing space!
8261 But just in case it doesn't...
8263 <h1><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: =">edit</a>]</span> <span class="mw-headline" id=".3D">=</span></h1>
8264 <p>The line above must have a trailing space!
8266 <h1><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: =">edit</a>]</span> <span class="mw-headline" id=".3D_2">=</span></h1>
8267 <p>But just in case it doesn't...
8272 Header with special characters (bug 25462)
8274 The tooltips shall not show entities to the user (ie. be double escaped)
8291 <p>The tooltips shall not show entities to the user (ie. be double escaped)
8293 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
8295 <li class="toclevel-1 tocsection-1"><a href="#text_.3E_text"><span class="tocnumber">1</span> <span class="toctext">text > text</span></a></li>
8296 <li class="toclevel-1 tocsection-2"><a href="#text_.3C_text"><span class="tocnumber">2</span> <span class="toctext">text < text</span></a></li>
8297 <li class="toclevel-1 tocsection-3"><a href="#text_.26_text"><span class="tocnumber">3</span> <span class="toctext">text & text</span></a></li>
8298 <li class="toclevel-1 tocsection-4"><a href="#text_.27_text"><span class="tocnumber">4</span> <span class="toctext">text ' text</span></a></li>
8299 <li class="toclevel-1 tocsection-5"><a href="#text_.22_text"><span class="tocnumber">5</span> <span class="toctext">text " text</span></a></li>
8302 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: text > text">edit</a>]</span> <span class="mw-headline" id="text_.3E_text">text > text</span></h2>
8305 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: text < text">edit</a>]</span> <span class="mw-headline" id="text_.3C_text">text < text</span></h2>
8308 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: text & text">edit</a>]</span> <span class="mw-headline" id="text_.26_text">text & text</span></h2>
8311 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: text ' text">edit</a>]</span> <span class="mw-headline" id="text_.27_text">text ' text</span></h2>
8314 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: text " text">edit</a>]</span> <span class="mw-headline" id="text_.22_text">text " text</span></h2>
8320 Headers with excess '=' characters
8321 (Are similar tests necessary beyond the 1st level?)
8325 =''italic'' heading==
8326 ==''italic'' heading=
8328 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
8330 <li class="toclevel-1 tocsection-1"><a href="#foo.3D"><span class="tocnumber">1</span> <span class="toctext">foo=</span></a></li>
8331 <li class="toclevel-1 tocsection-2"><a href="#.3Dfoo"><span class="tocnumber">2</span> <span class="toctext">=foo</span></a></li>
8332 <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>
8333 <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>
8336 <h1><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: foo=">edit</a>]</span> <span class="mw-headline" id="foo.3D">foo=</span></h1>
8337 <h1><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: =foo">edit</a>]</span> <span class="mw-headline" id=".3Dfoo">=foo</span></h1>
8338 <h1><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: italic heading=">edit</a>]</span> <span class="mw-headline" id="italic_heading.3D"><i>italic</i> heading=</span></h1>
8339 <h1><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: =italic heading">edit</a>]</span> <span class="mw-headline" id=".3Ditalic_heading">=<i>italic</i> heading</span></h1>
8344 HTML headers vs TOC (bug 23393)
8345 (__NOEDITSECTION__ for clearer output, doesn't matter here)
8357 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
8359 <li class="toclevel-1"><a href="#Header_1"><span class="tocnumber">1</span> <span class="toctext">Header 1</span></a>
8361 <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>
8362 <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>
8365 <li class="toclevel-1"><a href="#Header_2"><span class="tocnumber">2</span> <span class="toctext">Header 2</span></a>
8367 <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>
8368 <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>
8373 <h1> <span class="mw-headline" id="Header_1">Header 1</span></h1>
8374 <h2> <span class="mw-headline" id="Header_1.1">Header 1.1</span></h2>
8375 <h2> <span class="mw-headline" id="Header_1.2">Header 1.2</span></h2>
8376 <h1> <span class="mw-headline" id="Header_2">Header 2</span></h1>
8377 <h2> <span class="mw-headline" id="Header_2.1">Header 2.1</span></h2>
8378 <h2> <span class="mw-headline" id="Header_2.2">Header 2.2</span></h2>
8383 BUG 1219 URL next to image (broken)
8385 http://example.com[[Image:foobar.jpg]]
8387 <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>
8392 Bug 1186 news: in the middle of text
8394 http://en.wikinews.org/wiki/Wikinews:Workplace
8396 <p><a rel="nofollow" class="external free" href="http://en.wikinews.org/wiki/Wikinews:Workplace">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
8402 Namespaced link must have a title
8411 Namespaced link must have a title (bad fragment version)
8413 [[Project:#fragment]]
8415 <p>[[Project:#fragment]]
8421 ### HTML tags and HTML attributes
8425 div with no attributes
8427 <div>HTML rocks</div>
8429 <div>HTML rocks</div>
8434 div with double-quoted attribute
8436 <div id="rock">HTML rocks</div>
8438 <div id="rock">HTML rocks</div>
8443 div with single-quoted attribute
8445 <div id='rock'>HTML rocks</div>
8447 <div id="rock">HTML rocks</div>
8452 div with unquoted attribute
8454 <div id=rock>HTML rocks</div>
8456 <div id="rock">HTML rocks</div>
8461 div with illegal double attributes
8463 <div id="a" id="b">HTML rocks</div>
8465 <div id="b">HTML rocks</div>
8469 # FIXME: produce empty string instead of "class" in the PHP parser, following
8472 div with empty attribute value, space before equals
8476 <div class =>HTML rocks</div>
8478 <div class="">HTML rocks</div>
8482 # The PHP parser escapes the opening brace to { for some reason, so
8483 # disabled this test for it.
8485 div with braces in attribute value
8489 <div title="{}">Foo</div>
8491 <div title="{}">Foo</div>
8494 # This it very inconsistent in the PHP parser: it returns
8495 # class="class" if there is a space between the name and the equal sign (see
8496 # 'div with empty attribute value, space before equals'), but strips the
8497 # attribute completely if the space is missing. We hope that not much content
8498 # depends on this, so are implementing the behavior below in Parsoid for
8499 # consistencies' sake. Disabled for the PHP parser.
8500 # FIXME: fix this behavior in the PHP parser?
8502 div with empty attribute value, no space before equals
8506 <div class=>HTML rocks</div>
8508 <div class="">HTML rocks</div>
8513 HTML multiple attributes correction
8515 <p class="error" class="awesome">Awesome!</p>
8517 <p class="awesome">Awesome!</p>
8522 Table multiple attributes correction
8525 !+ class="error" class="awesome"| status
8530 <th class="awesome"> status
8538 <DIV ID="x">HTML ROCKS</DIV>
8540 <div id="x">HTML ROCKS</div>
8545 Non-ASCII pseudo-tags are rendered as text
8554 Pseudo-tag with URL 'name' renders as url link
8556 <http://example.com/>
8558 <p><<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>>
8563 text with amp in the middle of nowhere
8567 <p>Remember AT&T?
8572 text with character entity: eacute
8574 I always thought é was a cute letter.
8576 <p>I always thought é was a cute letter.
8581 text with entity-escaped character entity-like string: eacute
8583 I always thought &eacute; was a cute letter.
8585 <p>I always thought &eacute; was a cute letter.
8590 text with undefined character entity: xacute
8592 I always thought &xacute; was a cute letter.
8594 <p>I always thought &xacute; was a cute letter.
8606 [[Media:Foobar.jpg]]
8608 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Media:Foobar.jpg</a>
8613 Media link with text
8615 [[Media:Foobar.jpg|A neat file to look at]]
8617 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">A neat file to look at</a>
8621 # FIXME: this is still bad HTML tag nesting
8623 Media link with nasty text
8624 fixme: doBlockLevels won't wrap this in a paragraph because it contains a div
8626 [[Media:Foobar.jpg|Safe Link<div style=display:none>" onmouseover="alert(document.cookie)" onfoo="</div>]]
8628 <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>
8633 Media link to nonexistent file (bug 1702)
8635 [[Media:No such.jpg]]
8637 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="No such.jpg">Media:No such.jpg</a>
8642 Image link to nonexistent file (bug 1850 - good)
8644 [[Image:No such.jpg]]
8646 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="File:No such.jpg">File:No such.jpg</a>
8651 :Image link to nonexistent file (bug 1850 - bad)
8653 [[:Image:No such.jpg]]
8655 <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>
8662 Character reference normalization in link text (bug 1938)
8664 [[Main Page|this&that]]
8666 <p><a href="/wiki/Main_Page" title="Main Page">this&that</a>
8673 Test for unicode normalization
8675 The page's name is U+05d0 U+05b7, with non-canonical form U+FB2E
8679 (bug 19451) Links should refer to the normalized form.
8687 <p><a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
8688 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
8689 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
8690 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
8691 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
8696 Empty attribute crash test (bug 2067)
8698 <font color="">foo</font>
8700 <p><font color="">foo</font>
8705 Empty attribute crash test single-quotes (bug 2067)
8707 <font color=''>foo</font>
8709 <p><font color="">foo</font>
8714 Attribute test: equals, then nothing
8716 <font color=>foo</font>
8723 Attribute test: unquoted value
8725 <font color=x>foo</font>
8727 <p><font color="x">foo</font>
8732 Attribute test: unquoted but illegal value (hash)
8734 <font color=#x>foo</font>
8736 <p><font color="#x">foo</font>
8741 Attribute test: no value
8743 <font color>foo</font>
8745 <p><font color="color">foo</font>
8750 Bug 2095: link with three closing brackets
8754 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>]
8759 Bug 2095: link with pipe and three closing brackets
8763 <p><a href="/wiki/Main_Page" title="Main Page">link</a>]
8768 Bug 2095: link with pipe and three closing brackets, version 2
8770 [[Main Page|[http://example.com/]]]
8772 <p><a href="/wiki/Main_Page" title="Main Page">[http://example.com/]</a>
8782 Template:Dangerous attribute
8784 " onmouseover="alert(document.cookie)
8788 Template:Dangerous style attribute
8790 border-size: expression(alert(document.cookie))
8796 <div style="float: right; {{{1}}}">Magic div</div>
8800 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
8802 <div title="{{test}}"></div>
8804 <div title="This is a test template"></div>
8809 Bug 2304: HTML attribute safety (dangerous template; 2309)
8811 <div title="{{dangerous attribute}}"></div>
8813 <div title=""></div>
8818 Bug 2304: HTML attribute safety (dangerous style template; 2309)
8820 <div style="{{dangerous style attribute}}"></div>
8822 <div style="/* insecure input */"></div>
8827 Bug 2304: HTML attribute safety (safe parameter; 2309)
8829 {{div style|width: 200px}}
8831 <div style="float: right; width: 200px">Magic div</div>
8836 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
8838 {{div style|width: expression(alert(document.cookie))}}
8840 <div style="/* insecure input */">Magic div</div>
8845 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
8847 {{div style|"><script>alert(document.cookie)</script>}}
8849 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
8854 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
8856 {{div style|" ><script>alert(document.cookie)</script>}}
8858 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
8863 Bug 2304: HTML attribute safety (link)
8865 <div title="[[Main Page]]"></div>
8867 <div title="[[Main Page]]"></div>
8872 Bug 2304: HTML attribute safety (italics)
8874 <div title="''foobar''"></div>
8876 <div title="''foobar''"></div>
8881 Bug 2304: HTML attribute safety (bold)
8883 <div title="'''foobar'''"></div>
8885 <div title="'''foobar'''"></div>
8891 Bug 2304: HTML attribute safety (ISBN)
8893 <div title="ISBN 1234567890"></div>
8895 <div title="ISBN 1234567890"></div>
8900 Bug 2304: HTML attribute safety (RFC)
8902 <div title="RFC 1234"></div>
8904 <div title="RFC 1234"></div>
8909 Bug 2304: HTML attribute safety (PMID)
8911 <div title="PMID 1234567890"></div>
8913 <div title="PMID 1234567890"></div>
8918 Bug 2304: HTML attribute safety (web link)
8920 <div title="http://example.com/"></div>
8922 <div title="http://example.com/"></div>
8927 Bug 2304: HTML attribute safety (named web link)
8929 <div title="[http://example.com/ link]"></div>
8931 <div title="[http://example.com/ link]"></div>
8936 Bug 3244: HTML attribute safety (extension; safe)
8938 <div style="<nowiki>background:blue</nowiki>"></div>
8940 <div style="background:blue"></div>
8945 Bug 3244: HTML attribute safety (extension; unsafe)
8947 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
8949 <div style="/* insecure input */"></div>
8953 # More MSIE fun discovered by Tom Gilder
8956 MSIE CSS safety test: spurious slash
8958 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
8960 <div style="/* insecure input */">evil</div>
8965 MSIE CSS safety test: hex code
8967 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
8969 <div style="/* insecure input */">evil</div>
8974 MSIE CSS safety test: comment in url
8976 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
8978 <div style="background-image:u rl(javascript:alert('boo'))">evil</div>
8983 MSIE CSS safety test: comment in expression
8985 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
8987 <div style="background-image:expres sion(alert('boo4'))">evil4</div>
8993 Table attribute legitimate extension
8996 !+ style="<nowiki>color:blue</nowiki>"| status
9001 <th style="color:blue"> status
9007 Table attribute safety
9010 !+ style="<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>"| status
9015 <th style="/* insecure input */"> status
9021 CSS line continuation 1
9023 <div style="background-image: u\ rl(test.jpg);"></div>
9025 <div style="/* insecure input */"></div>
9030 CSS line continuation 2
9032 <div style="background-image: u\ rl(test.jpg); "></div>
9034 <div style="/* insecure input */"></div>
9045 Expansion of multi-line templates in attribute values (bug 6255)
9047 <div style="background: {{identity|#00FF00}}">-</div>
9049 <div style="background: #00FF00">-</div>
9055 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
9057 <div style="background:
9060 <div style="background: #00FF00">-</div>
9065 Expansion of multi-line templates in attribute values (bug 6255 sanity check 2)
9067 <div style="background: #00FF00">-</div>
9069 <div style="background: #00FF00">-</div>
9074 ### Parser hooks (see maintenance/parserTestsParserHook.php for the <tag> extension)
9077 Parser hook: empty input
9090 Parser hook: empty input using terminated empty elements
9103 Parser hook: empty input using terminated empty elements (space before)
9116 Parser hook: basic input
9130 Parser hook: case insensitive
9144 Parser hook: case insensitive, redux
9157 Parser hook: nested tags
9161 <tag><tag></tag></tag>
9172 Parser hook: basic arguments
9174 <tag width=200 height = "100" depth = '50' square></tag>
9182 'square' => 'square',
9189 Parser hook: argument containing a forward slash (bug 5344)
9191 <tag filename='/tmp/bla'></tag>
9196 'filename' => '/tmp/bla',
9203 Parser hook: empty input using terminated empty elements (bug 2374)
9216 # </tag> should be output literally since there is no matching tag that begins it
9218 Parser hook: basic arguments using terminated empty elements (bug 2374)
9220 <tag width=200 height = "100" depth = '50' square/>
9230 'square' => 'square',
9239 ### (see maintenance/parserTestsStaticParserHook.php for the <statictag> extension)
9243 Parser hook: static parser hook not inside a comment
9245 <statictag>hello, world</statictag>
9246 <statictag action=flush/>
9254 Parser hook: static parser hook inside a comment
9256 <!-- <statictag>hello, world</statictag> -->
9257 <statictag action=flush/>
9263 # Nested template calls; this case was broken by Parser.php rev 1.506,
9267 Template:One-parameter
9269 (My parameter is: {{{1}}})
9273 Template:Map-one-parameter
9279 Nested template calls
9281 {{Map-one-parameter|One-parameter|param}}
9283 <p>(My parameter is: param)
9292 Sanitizer: Closing of open tags
9294 <s></s><table></table>
9296 <s></s><table></table>
9301 Sanitizer: Closing of open but not closed tags
9310 Sanitizer: Closing of closed but not open tags
9319 Sanitizer: Closing of closed but not open table tags
9321 Table not started</td></tr></table>
9323 <p>Table not started</td></tr></table>
9328 Sanitizer: Escaping of spaces, multibyte characters, colons & other stuff in id=""
9330 <span id="æ: v">byte</span>[[#æ: v|backlink]]
9332 <p><span id=".C3.A6:_v">byte</span><a href="#.C3.A6:_v">backlink</a>
9337 Sanitizer: Validating the contents of the id attribute (bug 4515)
9343 Something, but definitely not <br id="9" />...
9347 Sanitizer: Validating id attribute uniqueness (bug 4515, bug 6301)
9351 <br id="foo" /><br id="foo" />
9353 Something need to be done. foo-2 ?
9357 Sanitizer: Validating that <meta> and <link> work, but only for Microdata
9360 <meta itemprop="hello" content="world">
9361 <meta http-equiv="refresh" content="5">
9362 <meta itemprop="hello" http-equiv="refresh" content="5">
9363 <link itemprop="hello" href="{{SERVER}}">
9364 <link rel="stylesheet" href="{{SERVER}}">
9365 <link rel="stylesheet" itemprop="hello" href="{{SERVER}}">
9368 <div itemscope="itemscope">
9369 <p> <meta itemprop="hello" content="world" />
9370 <meta http-equiv="refresh" content="5">
9371 <meta itemprop="hello" content="5" />
9373 <link itemprop="hello" href="http://example.org" />
9374 <link rel="stylesheet" href="<a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>">
9375 <link itemprop="hello" href="http://example.org" />
9381 Language converter: output gets cut off unexpectedly (bug 5757)
9385 this bit is safe: }-
9387 but if we add a conversion instance: -{zh-cn:xxx;zh-tw:yyy}-
9389 then we get cut off here: }-
9391 all additional text is vanished
9393 <p>this bit is safe: }-
9394 </p><p>but if we add a conversion instance: xxx
9395 </p><p>then we get cut off here: }-
9396 </p><p>all additional text is vanished
9401 Self closed html pairs (bug 5487)
9404 <center><font id="bug" />Centered text</center>
9405 <div><font id="bug2" />In div text</div>
9407 <center><font id="bug" />Centered text</center>
9408 <div><font id="bug2" />In div text</div>
9417 Punctuation: nbsp before exclamation
9421 <p>C'est grave !
9426 Punctuation: CSS !important (bug 11874)
9428 <div style="width:50% !important">important</div>
9430 <div style="width:50% !important">important</div>
9435 Punctuation: CSS ! important (bug 11874; with space after)
9437 <div style="width:50% ! important">important</div>
9439 <div style="width:50% ! important">important</div>
9445 HTML bullet list, closed tags (bug 5497)
9460 HTML bullet list, unclosed tags (bug 5497)
9477 HTML ordered list, closed tags (bug 5497)
9492 HTML ordered list, unclosed tags (bug 5497)
9509 HTML nested bullet list, closed tags (bug 5497)
9534 HTML nested bullet list, open tags (bug 5497)
9559 HTML nested ordered list, closed tags (bug 5497)
9584 HTML nested ordered list, open tags (bug 5497)
9609 HTML ordered list item with parameters oddity
9611 <ol><li id="fragment">One</li></ol>
9613 <ol><li id="fragment">One</li></ol>
9618 bug 5918: autonumbering
9620 [http://first/] [http://second] [ftp://ftp]
9624 [mailto:enclosed@mail.tld With target]
9626 [mailto:enclosed@mail.tld]
9628 mailto:inline@mail.tld
9630 <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>
9631 </p><p><a rel="nofollow" class="external free" href="ftp://inlineftp">ftp://inlineftp</a>
9632 </p><p><a rel="nofollow" class="external text" href="mailto:enclosed@mail.tld">With target</a>
9633 </p><p><a rel="nofollow" class="external autonumber" href="mailto:enclosed@mail.tld">[4]</a>
9634 </p><p><a rel="nofollow" class="external free" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a>
9640 # Security and HTML correctness
9641 # From Nick Jenkins' fuzz testing
9645 Fuzz testing: Parser13
9660 Fuzz testing: Parser14
9665 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: onmouseover=">edit</a>]</span> <span class="mw-headline" id="onmouseover.3D">onmouseover=</span></h2>
9666 http://<table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
9668 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
9675 Fuzz testing: Parser14-table
9680 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: a">edit</a>]</span> <span class="mw-headline" id="a">a</span></h2>
9681 <table style="__TOC__">
9687 # Known to produce bogus xml (extra </td>)
9689 Fuzz testing: Parser16
9709 Fuzz testing: Parser21
9712 ! irc://{{ftp://a" onmouseover="alert('hello world');"
9717 <th> <a rel="nofollow" class="external free" href="irc://{{ftp://a">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
9727 Fuzz testing: Parser22
9729 http://===r:::https://b
9733 <p><a rel="nofollow" class="external free" href="http://===r:::https://b">http://===r:::https://b</a>
9741 # Known to produce bad XML for now
9743 Fuzz testing: Parser24
9750 | {{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}} >
9751 <br style="onmouseover='alert(document.cookie);' " />
9753 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
9758 <u class="|">}}}} >
9759 <br style="onmouseover='alert(document.cookie);'" />
9761 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
9770 # Note: the current result listed for this is not what the original one was,
9771 # but the original bug was JavaScript injection, which is fixed in any case.
9772 # It's not clear that the original result listed was any more correct than the
9773 # current one. Original result:
9776 # <li class="||">
9777 # }}}blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
9779 Fuzz testing: Parser25 (bug 6055)
9785 }}}blah" onmouseover="alert('hello world');" align="left"'''MOVE MOUSE CURSOR OVER HERE
9787 <p><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
9792 Fuzz testing: URL adjacent extension (with space, clean)
9795 http://example.com <nowiki>junk</nowiki>
9797 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> junk
9802 Fuzz testing: URL adjacent extension (no space, dirty; nowiki)
9805 http://example.com<nowiki>junk</nowiki>
9807 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>junk
9812 Fuzz testing: URL adjacent extension (no space, dirty; pre)
9815 http://example.com<pre>junk</pre>
9817 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><pre>junk</pre>
9822 Fuzz testing: image with bogus manual thumbnail
9824 [[Image:foobar.jpg|thumbnail= ]]
9826 <div class="thumb tright"><div class="thumbinner" style="width:182px;">Error creating thumbnail: <div class="thumbcaption"></div></div></div>
9831 Fuzz testing: encoded newline in generated HTML replacements (bug 6577)
9833 <pre dir=" "></pre>
9835 <pre dir=" "></pre>
9840 Parsing optional HTML elements (Bug 6171)
9845 <td> Some tabular data</td>
9846 <td> More tabular data ...
9847 <td> And yet som tabular data</td>
9853 <td> Some tabular data</td>
9854 <td> More tabular data ...
9855 </td><td> And yet som tabular data</td>
9862 Correct handling of <td>, <tr> (Bug 6171)
9867 <td> Some tabular data</td>
9868 <td> More tabular data ...</td>
9869 <td> And yet som tabular data</td>
9875 <td> Some tabular data</td>
9876 <td> More tabular data ...</td>
9877 <td> And yet som tabular data</td>
9885 Parsing crashing regression (fr:JavaScript)
9889 <p></body></x>
9894 Inline wiki vs wiki block nesting
9900 <p><b>Bold paragraph</b>
9901 </p><p>New wiki paragraph
9906 Inline HTML vs wiki block nesting
9914 <p><b>Bold paragraph</b>
9915 </p><p>New wiki paragraph
9919 # Original result was this:
9920 # <p><b>bold</b><b>bold<i>bolditalics</i></b>
9922 # While that might be marginally more intuitive, maybe, the six-apostrophe
9923 # construct is clearly pathological and the result stated here (which is what
9924 # the parser actually does) is about as reasonable as anything.
9926 Mixing markup for italics and bold
9929 '''bold''''''bold''bolditalics'''''
9931 <p>'<i>bold'</i><b>bold<i>bolditalics</i></b>
9939 Article for special page transclusion test
9943 Special page transclusion
9946 {{Special:Prefixindex/Xyzzyx}}
9948 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
9953 Special page transclusion twice (bug 5021)
9956 {{Special:Prefixindex/Xyzzyx}}
9957 {{Special:Prefixindex/Xyzzyx}}
9959 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
9960 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
9965 Transclusion of default MediaWiki message
9967 {{MediaWiki:Mainpage}}
9974 Transclusion of nonexistent MediaWiki message
9976 {{MediaWiki:Mainpagexxx}}
9978 <p><a href="/index.php?title=MediaWiki:Mainpagexxx&action=edit&redlink=1" class="new" title="MediaWiki:Mainpagexxx (page does not exist)">MediaWiki:Mainpagexxx</a>
9983 Transclusion of MediaWiki message with underscore
9985 {{MediaWiki:history_short}}
9992 Transclusion of MediaWiki message with space
9994 {{MediaWiki:history short}}
10001 Invalid header with following text
10011 Section extraction test (section 0)
10031 Section extraction test (section 1)
10053 Section extraction test (section 2)
10074 Section extraction test (section 3)
10094 Section extraction test (section 4)
10118 Section extraction test (section 5)
10138 Section extraction test (section 6)
10159 Section extraction test (section 7)
10179 Section extraction test (section 8)
10199 Section extraction test (section 9)
10220 Section extraction test (section 10)
10240 Section extraction test (nonexistent section 11)
10259 Section extraction test with bogus heading (section 1)
10264 ==bogus== not a legal section
10268 ==bogus== not a legal section
10272 Section extraction test with bogus heading (section 2)
10277 ==bogus== not a legal section
10284 Section extraction test with comment after heading (section 1)
10296 Section extraction test with comment after heading (section 2)
10308 Section extraction test with bogus <nowiki> heading (section 1)
10313 ==bogus== <nowiki>not a legal section</nowiki>
10317 ==bogus== <nowiki>not a legal section</nowiki>
10321 Section extraction test with bogus <nowiki> heading (section 2)
10326 ==bogus== <nowiki>not a legal section</nowiki>
10333 # Formerly testing for bug 2587, now resolved by the use of unmarked sections
10334 # instead of respecting commented sections
10336 Section extraction prefixed by comment (section 1)
10347 Section extraction prefixed by comment (section 2)
10358 # Formerly testing for bug 2607, now resolved by the use of unmarked sections
10359 # instead of respecting HTML-style headings
10361 Section extraction, mixed wiki and html (section 1)
10377 Section extraction, mixed wiki and html (section 2)
10393 # Formerly testing for bug 3342
10395 Section extraction, heading surrounded by <noinclude>
10399 <noinclude>==unmarked==</noinclude>
10405 # Test behavior of bug 19910
10407 Sectiion with all-equals
10412 The line above must have a trailing space
10415 But just in case it doesn't...
10419 But just in case it doesn't...
10423 Section replacement test (section 0)
10454 Section replacement test (section 1)
10483 Section replacement test (section 2)
10513 Section replacement test (section 3)
10544 Section replacement test (section 4)
10571 Section replacement test (section 5)
10602 Section replacement test (section 6)
10632 Section replacement test (section 7)
10663 Section replacement test (section 8)
10694 Section replacement test (section 9)
10723 Section replacement test (section 10)
10753 Section replacement test with initial whitespace (bug 13728)
10757 Preformatted initial line
10761 Preformatted initial line
10768 Section extraction, heading followed by pre with 20 spaces (bug 6398)
10780 Section extraction, heading followed by pre with 19 spaces (bug 6398 sanity check)
10793 Section extraction, <pre> around bogus header (bug 10309)
10810 Section replacement, <pre> around bogus header (bug 10309)
10812 noxml replace=2,"xxx"
10833 Handling of 
 in URLs
10837 <ul><li><ul><li><a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a>
10844 5 quotes, code coverage +1 line (php)
10851 # The PHP parser strips the empty tags out for giggles; parsoid doesn't.
10853 5 quotes, code coverage +1 line (parsoid)
10859 <p><i><b></b></i></p>
10863 Special:Search page linking.
10867 <p><a href="/wiki/Special:Search" title="Special:Search">Special:Search</a>
10879 * {{BASEPAGENAMEE}}
10881 * {{TALKPAGENAMEE}}
10882 * {{SUBJECTPAGENAME}}
10883 * {{SUBJECTPAGENAMEE}}
10889 * {{SUBJECTSPACEE}}
10890 * {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}
10892 <ul><li> Parser test
10893 </li><li> Parser test
10894 </li><li> Parser test
10895 </li><li> Parser_test
10896 </li><li> Parser test
10897 </li><li> Parser_test
10898 </li><li> Talk:Parser test
10899 </li><li> Talk:Parser_test
10900 </li><li> Parser test
10901 </li><li> Parser_test
10908 </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>
10912 ### Note: Above tests excludes the "{{NUMBEROFADMINS}}" magic word because it generates a MySQL error when included.
10922 image4 |300px| centre
10923 image5.svg| http://///////
10928 <ul class="gallery">
10929 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10930 <div style="height: 150px;">Image1.png</div>
10931 <div class="gallerytext">
10934 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10935 <div style="height: 150px;">Image2.gif</div>
10936 <div class="gallerytext">
10941 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10942 <div style="height: 150px;">Image3</div>
10943 <div class="gallerytext">
10946 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10947 <div style="height: 150px;">Image4</div>
10948 <div class="gallerytext">
10953 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10954 <div style="height: 150px;">Image5.svg</div>
10955 <div class="gallerytext">
10956 <p><a rel="nofollow" class="external free" href="http://///////">http://///////</a>
10960 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10961 <div style="height: 150px;">* image6</div>
10962 <div class="gallerytext">
10970 Gallery (with options)
10972 <gallery widths='70px' heights='40px' perrow='2' caption='Foo [[Main Page]]' >
10973 File:Nonexistant.jpg|caption
10974 File:Nonexistant.jpg
10975 image:foobar.jpg|some '''caption''' [[Main Page]]
10977 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
10980 <ul class="gallery" style="max-width: 226px;_width: 226px;">
10981 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
10982 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
10983 <div style="height: 70px;">Nonexistant.jpg</div>
10984 <div class="gallerytext">
10989 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
10990 <div style="height: 70px;">Nonexistant.jpg</div>
10991 <div class="gallerytext">
10994 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
10995 <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>
10996 <div class="gallerytext">
10997 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
11001 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
11002 <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>
11003 <div class="gallerytext">
11006 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
11007 <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>
11008 <div class="gallerytext">
11018 Gallery with wikitext inside caption
11021 File:foobar.jpg|[[File:foobar.jpg|20px|desc|alt=inneralt]]|alt=galleryalt
11022 File:foobar.jpg|{{Test|unamedParam|alt=param}}|alt=galleryalt
11025 <ul class="gallery">
11026 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
11027 <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>
11028 <div class="gallerytext">
11029 <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>
11033 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
11034 <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>
11035 <div class="gallerytext">
11036 <p>This is a test template
11045 gallery (with showfilename option)
11047 <gallery showfilename>
11048 File:Nonexistant.jpg|caption
11049 File:Nonexistant.jpg
11050 image:foobar.jpg|some '''caption''' [[Main Page]]
11054 <ul class="gallery">
11055 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
11056 <div style="height: 150px;">Nonexistant.jpg</div>
11057 <div class="gallerytext">
11058 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
11063 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
11064 <div style="height: 150px;">Nonexistant.jpg</div>
11065 <div class="gallerytext">
11066 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
11070 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
11071 <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>
11072 <div class="gallerytext">
11073 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
11074 some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
11078 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
11079 <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>
11080 <div class="gallerytext">
11081 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
11090 Gallery (with namespace-less filenames)
11093 File:Nonexistant.jpg
11099 <ul class="gallery">
11100 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
11101 <div style="height: 150px;">Nonexistant.jpg</div>
11102 <div class="gallerytext">
11105 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
11106 <div style="height: 150px;">Nonexistant.jpg</div>
11107 <div class="gallerytext">
11110 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
11111 <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>
11112 <div class="gallerytext">
11115 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
11116 <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>
11117 <div class="gallerytext">
11125 HTML Hex character encoding (spells the word "JavaScript")
11127 JavaScript
11129 <p>JavaScript
11134 HTML Hex character encoding bogus encoding (bug 26437 regression check)
11138 <p>&#xsee;&#XSEE;
11143 HTML Hex character encoding mixed case
11152 __FORCETOC__ override
11164 ISBN 978-0-1234-56 789
11166 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789
11171 ISBN followed by 5 spaces
11182 ISBN ISBN 1234567890
11184 <p>ISBN <a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
11189 Bug 22905: <abbr> followed by ISBN followed by </a>
11191 <abbr>(fr)</abbr> ISBN 2753300917 [http://www.example.com example.com]
11193 <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>
11202 <p>RFC <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a>
11207 Double RFC with a wiki link
11211 <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>
11220 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987
11225 Centre-aligned image
11227 [[Image:foobar.jpg|centre]]
11229 <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>
11236 [[Image:foobar.jpg|none]]
11238 <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>
11243 Width + Height sized image (using px) (height is ignored)
11245 [[Image:foobar.jpg|640x480px]]
11247 <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>
11252 Width-sized image (using px, no following whitespace)
11254 [[Image:foobar.jpg|640px]]
11256 <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>
11261 Width-sized image (using px, with following whitespace - test regression from r39467)
11263 [[Image:foobar.jpg|640px ]]
11265 <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>
11270 Width-sized image (using px, with preceding whitespace - test regression from r39467)
11272 [[Image:foobar.jpg| 640px]]
11274 <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>
11279 Another italics / bold test
11287 # Note the results may be incorrect, as parserTest output included this:
11288 # XML error: Mismatched tag at byte 6120:
11289 # ...<dd> </dt></dl> </dd...
11297 <dl><dd><dl><dt><dl><dt><dl><dt><dl><dd><dl><dd>
11308 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
11310 Images with the "|" character in the comment
11312 [[image:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]]
11314 <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>
11319 [Before] HTML without raw HTML enabled ($wgRawHtml==false)
11321 <html><script>alert(1);</script></html>
11323 <p><html><script>alert(1);</script></html>
11328 HTML with raw HTML ($wgRawHtml==true)
11332 <html><script>alert(1);</script></html>
11334 <p><script>alert(1);</script>
11339 Parents of subpages, one level up
11341 subpage title=[[Subpage test/L1/L2/L3]]
11345 <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>
11351 Parents of subpages, one level up, not named
11353 subpage title=[[Subpage test/L1/L2/L3]]
11357 <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>
11364 Parents of subpages, two levels up
11366 subpage title=[[Subpage test/L1/L2/L3]]
11372 <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
11373 </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>
11378 Parents of subpages, two levels up, without trailing slash or name.
11380 subpage title=[[Subpage test/L1/L2/L3]]
11389 Parents of subpages, two levels up, with lots of extra trailing slashes.
11391 subpage title=[[Subpage test/L1/L2/L3]]
11395 <p><a href="/index.php?title=Subpage_test/L1////&action=edit&redlink=1" class="new" title="Subpage test/L1//// (page does not exist)">///</a>
11400 Definition list code coverage
11406 <dl><dt> title  </dt><dd> def
11407 </dd><dt> title </dt><dd> def
11408 </dd><dt>title</dt><dd> def
11414 Don't fall for the self-closing div
11416 <div>hello world</div/>
11418 <div>hello world</div>
11427 <p>[[:Template:Msg]]
11436 <p><a href="/index.php?title=Template:QUERTY&action=edit&redlink=1" class="new" title="Template:QUERTY (page does not exist)">Template:QUERTY</a>
11440 # This isn't needed for XHTML conformance, but would be handy as a fallback security measure
11442 Always escape literal '>' in output, not just after '<'
11456 <p>This is a test template
11457 This is a test template
11469 Inclusion of !userCanEdit() content
11473 <h2><span class="editsection">[<a href="/index.php?title=MediaWiki:Fake&action=edit&section=T-1" title="MediaWiki:Fake">edit</a>]</span> <span class="mw-headline" id="header">header</span></h2>
11479 Out-of-order TOC heading levels
11488 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
11490 <li class="toclevel-1 tocsection-1"><a href="#2"><span class="tocnumber">1</span> <span class="toctext">2</span></a>
11492 <li class="toclevel-2 tocsection-2"><a href="#6"><span class="tocnumber">1.1</span> <span class="toctext">6</span></a></li>
11493 <li class="toclevel-2 tocsection-3"><a href="#3"><span class="tocnumber">1.2</span> <span class="toctext">3</span></a></li>
11496 <li class="toclevel-1 tocsection-4"><a href="#1"><span class="tocnumber">2</span> <span class="toctext">1</span></a>
11498 <li class="toclevel-2 tocsection-5"><a href="#5"><span class="tocnumber">2.1</span> <span class="toctext">5</span></a></li>
11499 <li class="toclevel-2 tocsection-6"><a href="#2_2"><span class="tocnumber">2.2</span> <span class="toctext">2</span></a></li>
11504 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: 2">edit</a>]</span> <span class="mw-headline" id="2">2</span></h2>
11505 <h6><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: 6">edit</a>]</span> <span class="mw-headline" id="6">6</span></h6>
11506 <h3><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=3" title="Edit section: 3">edit</a>]</span> <span class="mw-headline" id="3">3</span></h3>
11507 <h1><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=4" title="Edit section: 1">edit</a>]</span> <span class="mw-headline" id="1">1</span></h1>
11508 <h5><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=5" title="Edit section: 5">edit</a>]</span> <span class="mw-headline" id="5">5</span></h5>
11509 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=6" title="Edit section: 2">edit</a>]</span> <span class="mw-headline" id="2_2">2</span></h2>
11515 ISBN with a dummy number
11525 ISBN with space-delimited number
11529 <p><a href="/wiki/Special:BookSources/9290170328" class="internal mw-magiclink-isbn">ISBN 92 9017 032 8</a>
11535 ISBN with multiple spaces, no number
11554 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
11555 </p><p>ISBN 12345678901
11561 ISBN with trailing year (bug 8110)
11563 ISBN 1-234-56789-0 - 2006
11565 ISBN 1 234 56789 0 - 2006
11567 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1-234-56789-0</a> - 2006
11568 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1 234 56789 0</a> - 2006
11576 {{anchorencode:foo bar©#%n}}
11578 <p>foo_bar.C2.A9.23.25n
11583 anchorencode trims spaces
11585 {{anchorencode: __pretty__please__}}
11592 anchorencode deals with links
11594 {{anchorencode: [[hello|world]] [[hi]]}}
11601 anchorencode deals with templates
11603 {{anchorencode: {{Foo}} }}
11610 anchorencode encodes like the TOC generator: (bug 18431)
11612 === _ +:.3A%3A&&]] ===
11613 {{anchorencode: _ +:.3A%3A&&]] }}
11616 <h3> <span class="mw-headline" id=".2B:.3A.253A.26.26.5D.5D">_ +:.3A%3A&&]]</span></h3>
11617 <p>.2B:.3A.253A.26.26.5D.5D
11621 # Expected output in the following test is not necessarily expected (there
11622 # should probably be <p> tags inside the <blockquote> in the output) -- it's
11623 # only testing for well-formedness.
11625 Bug 6200: blockquotes and paragraph formatting
11645 Bug 8293: Use of center tag ruins paragraph formatting
11667 ### Language variants related tests
11670 Self-link in language variants
11672 title=[[Dunav]] language=sr
11674 Both [[Dunav]] and [[Дунав]] are names for this river.
11676 <p>Both <strong class="selflink">Dunav</strong> and <strong class="selflink">Дунав</strong> are names for this river.
11687 Link to another existing title shouldn't be parsed as self-link even if it's a variant of this title
11689 title=[[Duna]] language=sr
11691 [[Дуна]] is not a self-link while [[Duna]] and [[Dуна]] are still self-links.
11693 <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.
11698 Link to pages in language variants
11702 Main Page can be written as [[Маин Паге]]
11704 <p>Main Page can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>
11710 Multiple links to pages in language variants
11714 [[Main Page]] can be written as [[Маин Паге]] same as [[Маин Паге]].
11716 <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>.
11722 Simple template in language variants
11728 <p>This is a test template
11734 Template with explicit namespace in language variants
11740 <p>This is a test template
11746 Basic test for template parameter in language variants
11750 {{парамтест|param=foo}}
11752 <p>This is a test template with parameter foo
11758 Simple category in language variants
11762 [[Category:МедиаWики Усер'с Гуиде]]
11764 <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>
11781 Don't convert blue categorylinks to another variant (bug 33210)
11785 [[A]][[Category:分类]]
11787 <a href="/wiki/Category:%E5%88%86%E7%B1%BB" title="Category:分类">分类</a>
11792 Stripping -{}- tags (language variants)
11796 Latin proverb: -{Ne nuntium necare}-
11798 <p>Latin proverb: Ne nuntium necare
11804 Prevent conversion with -{}- tags (language variants)
11806 language=sr variant=sr-ec
11808 Latinski: -{Ne nuntium necare}-
11810 <p>Латински: Ne nuntium necare
11816 Prevent conversion of text with -{}- tags (language variants)
11818 language=sr variant=sr-ec
11820 Latinski: -{Ne nuntium necare}-
11822 <p>Латински: Ne nuntium necare
11828 Prevent conversion of links with -{}- tags (language variants)
11830 language=sr variant=sr-ec
11834 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
11840 -{}- tags within headlines (within html for parserConvert())
11842 language=sr variant=sr-ec
11846 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Уредите одељак „Naslov“">уреди</a>]</span> <span class="mw-headline" id="-.7BNaslov.7D-">Naslov</span></h2>
11852 Explicit definition of language variant alternatives
11854 language=zh variant=zh-tw
11856 -{zh:China;zh-tw:Taiwan}-, not China
11858 <p>Taiwan, not China
11864 Conversion around HTML tags
11866 language=sr variant=sr-ec
11868 -{H|span=>sr-ec:script;title=>sr-ec:src;}-
11869 <span title="La-{sr-el:L;sr-ec:C;}-tin">ski</span>
11872 <span title="ЛаCтин">ски</span>
11878 Explicit session-wise language variant mapping (A flag and - flag)
11880 language=zh variant=zh-tw
11882 Taiwan is not China.
11883 But -{A|zh:China;zh-tw:Taiwan}- is China,
11884 (This-{-|zh:China;zh-tw:Taiwan}- should be stripped!)
11885 and -{China}- is China.
11887 <p>Taiwan is not China.
11888 But Taiwan is Taiwan,
11889 (This should be stripped!)
11890 and China is China.
11895 Explicit session-wise language variant mapping (H flag for hide)
11897 language=zh variant=zh-tw
11899 (This-{H|zh:China;zh-tw:Taiwan}- should be stripped!)
11902 <p>(This should be stripped!)
11908 Adding explicit conversion rule for title (T flag)
11910 language=zh variant=zh-tw showtitle
11912 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
11915 <p>Should be stripped!
11920 Testing that changing the language variant here in the tests actually works
11922 language=zh variant=zh showtitle
11924 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
11927 <p>Should be stripped!
11932 Recursive conversion of alt and title attrs shouldn't clear converter state
11934 language=zh variant=zh-cn showtitle
11936 -{H|zh-cn:Exclamation;zh-tw:exclamation;}-
11937 Should be stripped-{T|zh-cn:China;zh-tw:Taiwan}-<span title="exclamation">!</span>
11941 Should be stripped<span title="Exclamation">!</span>
11946 Bug 24072: more test on conversion rule for title
11948 language=zh variant=zh-tw showtitle
11950 This should be stripped-{T|zh:China;zh-tw:Taiwan}-!
11951 This won't take interferes with the title rule-{H|zh:Beijing;zh-tw:Taipei}-.
11954 <p>This should be stripped!
11955 This won't take interferes with the title rule.
11960 Raw output of variant escape tags (R flag)
11962 language=zh variant=zh-tw
11964 Raw: -{R|zh:China;zh-tw:Taiwan}-
11966 <p>Raw: zh:China;zh-tw:Taiwan
11971 Nested using of manual convert syntax
11973 language=zh variant=zh-hk
11975 Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiwan;zh-hk:H-{ong}- K-{}-ong;}-;}-!
11977 <p>Nested: Hello Hong Kong!
11982 Proper conversion of text in external links
11984 language=sr variant=sr-ec
11986 http://www.google.com
11987 gopher://www.google.com
11988 [http://www.google.com http://www.google.com]
11989 [gopher://www.google.com gopher://www.google.com]
11990 [https://www.google.com irc://www.google.com]
11991 [ftp://www.google.com www.google.com/ftp://dir]
11992 [//www.google.com www.google.com]
11994 <p><a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
11995 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
11996 <a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
11997 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
11998 <a rel="nofollow" class="external text" href="https://www.google.com">irc://www.google.com</a>
11999 <a rel="nofollow" class="external text" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
12000 <a rel="nofollow" class="external text" href="//www.google.com">www.гоогле.цом</a>
12005 Do not convert roman numbers to language variants
12007 language=sr variant=sr-ec
12011 <p>Фридрих IV је цар.
12016 Unclosed language converter markup "-{"
12027 Don't convert raw rule "-{R|=>}-" to "=>"
12044 Bug 529: Uncovered bullet
12054 # Plain MediaWiki does not remove empty lists, but tidy actually does.
12055 # Templates in Wikipedia rely on this behavior, as tidy has always been
12056 # enabled there. These tests are normally run *without* tidy, so specify the
12057 # full output here.
12058 # To test realistic parsing behavior, apply a tidy-like transformation to both
12059 # the expected output and your parser's output.
12061 Bug 529: Uncovered bullet leaving empty list, normally removed by tidy
12063 ******* Foo {{bullet}}
12065 <ul><li><ul><li><ul><li><ul><li><ul><li><ul><li><ul><li> Foo
12078 Bug 529: Uncovered table already at line-start
12101 Bug 529: Uncovered bullet in parser function result
12103 * Foo {{lc:{{bullet}} }}
12112 Bug 5678: Double-parsed template argument
12114 {{lc:{{{1}}}|hello}}
12121 Bug 5678: Double-parsed template invocation
12123 {{lc:{{paramtest {{!}} param = hello }} }}
12125 <p>{{paramtest | param = hello }}
12130 Case insensitivity of parser functions for non-ASCII characters (bug 8143)
12133 title=[[Main Page]]
12135 {{PRVNÍVELKÉ:ěščř}}
12136 {{prvnívelké:ěščř}}
12156 Morwen/13: Unclosed link followed by heading
12163 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: heading">edit</a>]</span> <span class="mw-headline" id="heading">heading</span></h2>
12168 HHP2.1: Heuristics for headings in preprocessor parenthetical structures
12175 <h1> <span class="mw-headline" id="heading">heading</span></h1>
12180 HHP2.2: Heuristics for headings in preprocessor parenthetical structures
12187 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: heading">edit</a>]</span> <span class="mw-headline" id="heading">heading</span></h2>
12202 Paragraphs inside divs (no extra line breaks)
12214 Paragraphs inside divs (extra line break on open)
12229 Paragraphs inside divs (extra line break on close)
12244 Paragraphs inside divs (extra line break on open and close)
12261 Nesting tags, paragraphs on lines which begin with <div>
12265 <div></div><strong>A
12274 # Bug 6200: <blockquote> should behave like <div> with respect to line breaks
12276 Bug 6200: paragraphs inside blockquotes (no extra line breaks)
12280 <blockquote>Line one
12282 Line two</blockquote>
12284 <blockquote>Line one
12285 Line two</blockquote>
12290 Bug 6200: paragraphs inside blockquotes (extra line break on open)
12297 Line two</blockquote>
12302 Line two</blockquote>
12307 Bug 6200: paragraphs inside blockquotes (extra line break on close)
12311 <blockquote>Line one
12316 <blockquote>Line one
12324 Bug 6200: paragraphs inside blockquotes (extra line break on open and close)
12343 Paragraphs inside blockquotes/divs (no extra line breaks)
12345 <blockquote><div>Line one
12347 Line two</div></blockquote>
12349 <blockquote><div>Line one
12350 Line two</div></blockquote>
12355 Paragraphs inside blockquotes/divs (extra line break on open)
12360 Line two</div></blockquote>
12365 Line two</div></blockquote>
12370 Paragraphs inside blockquotes/divs (extra line break on close)
12372 <blockquote><div>Line one
12375 </div></blockquote>
12377 <blockquote><div>Line one
12380 </div></blockquote>
12385 Paragraphs inside blockquotes/divs (extra line break on open and close)
12391 </div></blockquote>
12397 </div></blockquote>
12402 Interwiki links trounced by replaceExternalLinks after early LinkHolderArray expansion
12404 wgLinkHolderBatchSize=0
12410 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?1" class="extiw" title="meatball:1">meatball:1</a>
12411 <a href="http://www.usemod.com/cgi-bin/mb.pl?2" class="extiw" title="meatball:2">meatball:2</a>
12412 <a href="http://www.usemod.com/cgi-bin/mb.pl?3" class="extiw" title="meatball:3">meatball:3</a>
12417 Free external link invading image caption
12419 [[Image:Foobar.jpg|thumb|http://x|hello]]
12421 <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>
12426 Bug 15196: localised external link numbers
12430 [http://en.wikipedia.org/]
12432 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/">[۱]</a>
12437 Multibyte character in padleft
12439 {{padleft:-Hello|7|Æ}}
12446 Multibyte character in padright
12448 {{padright:Hello-|7|Æ}}
12455 formatdate parser function
12457 {{#formatdate:2009-03-24}}
12459 <p><span class="mw-formatted-date" title="2009-03-24">2009-03-24</span>
12464 formatdate parser function, with default format
12466 {{#formatdate:2009-03-24|mdy}}
12468 <p><span class="mw-formatted-date" title="2009-03-24">March 24, 2009</span>
12473 Spacing of numbers in formatted dates
12475 {{#formatdate:January 15}}
12477 <p><span class="mw-formatted-date" title="01-15">January 15</span>
12482 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
12484 language=nl title=[[MediaWiki:Common.css]]
12486 {{#formatdate:2009-03-24|dmy}}
12488 <p><span class="mw-formatted-date" title="2009-03-24">24 March 2009</span>
12501 Edit comment with link
12505 I like the [[Main Page]] a lot
12507 I like the <a href="/wiki/Main_Page" title="Main Page">Main Page</a> a lot
12511 Edit comment with link and link text
12515 I like the [[Main Page|best pages]] a lot
12517 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
12521 Edit comment with link and link text with suffix
12525 I like the [[Main Page|best page]]s a lot
12527 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
12531 Edit comment with section link (non-local, eg in history list)
12533 comment title=[[Main Page]]
12535 /* External links */ removed bogus entries
12537 <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
12541 Edit comment with section link and text before it (non-local, eg in history list)
12543 comment title=[[Main Page]]
12545 pre-comment text /* External links */ removed bogus entries
12547 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>
12551 Edit comment with section link (local, eg in diff view)
12553 comment local title=[[Main Page]]
12555 /* External links */ removed bogus entries
12557 <a href="#External_links">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
12561 Edit comment with subpage link (bug 14080)
12565 title=[[Subpage test]]
12567 Poked at a [[/subpage]] here...
12569 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a> here...
12573 Edit comment with subpage link and link text (bug 14080)
12577 title=[[Subpage test]]
12579 Poked at a [[/subpage|neat little page]] here...
12581 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">neat little page</a> here...
12585 Edit comment with bogus subpage link in non-subpage NS (bug 14080)
12588 title=[[Subpage test]]
12590 Poked at a [[/subpage]] here...
12592 Poked at a <a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a> here...
12596 Edit comment with bare anchor link (local, as on diff)
12600 title=[[Main Page]]
12604 <a href="#section">#section</a>
12608 Edit comment with bare anchor link (non-local, as on history)
12611 title=[[Main Page]]
12615 <a href="/wiki/Main_Page#section" title="Main Page">#section</a>
12619 Anchor starting with underscore
12623 <p><a href="#_ref">One</a>
12628 Id starting with underscore
12630 <div id="_ref"></div>
12632 <div id="_ref"></div>
12637 Space normalisation on autocomment (bug 22784)
12640 title=[[Main Page]]
12642 /* __hello__world__ */
12644 <a href="/wiki/Main_Page#hello_world" title="Main Page">→</a><span dir="auto"><span class="autocomment">__hello__world__</span></span>
12648 percent-encoding and + signs in comments (Bug 26410)
12652 [[ABC%33D% ++]] [[ABC%33D% ++|+%20]]
12654 <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>
12658 Bad images - basic functionality
12667 Bad images - bug 16039: text after bad image disappears
12681 Verify that displaytitle works (bug #22501) no displaytitle
12685 wgAllowDisplayTitle=true
12686 wgRestrictDisplayTitle=false
12688 this is not the the title
12691 <p>this is not the the title
12696 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=false
12701 wgAllowDisplayTitle=true
12702 wgRestrictDisplayTitle=false
12704 this is not the the title
12705 {{DISPLAYTITLE:whatever}}
12708 <p>this is not the the title
12713 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true mismatch
12718 wgAllowDisplayTitle=true
12719 wgRestrictDisplayTitle=true
12721 this is not the the title
12722 {{DISPLAYTITLE:whatever}}
12725 <p>this is not the the title
12730 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true matching
12735 wgAllowDisplayTitle=true
12736 wgRestrictDisplayTitle=true
12738 this is not the the title
12739 {{DISPLAYTITLE:screen}}
12742 <p>this is not the the title
12747 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false
12752 wgAllowDisplayTitle=false
12754 this is not the the title
12755 {{DISPLAYTITLE:screen}}
12758 <p>this is not the the title
12759 <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>
12764 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false no DISPLAYTITLE
12769 wgAllowDisplayTitle=false
12771 this is not the the title
12774 <p>this is not the the title
12779 preload: check <noinclude> and <includeonly>
12783 Hello <noinclude>cruel</noinclude><includeonly>kind</includeonly> world.
12789 preload: check <onlyinclude>
12793 Goodbye <onlyinclude>Hello world</onlyinclude>
12799 preload: can pass tags through if we want to
12803 <includeonly><</includeonly>includeonly>Hello world<includeonly><</includeonly>/includeonly>
12805 <includeonly>Hello world</includeonly>
12809 preload: check that it doesn't try to do tricks
12813 * <!-- Hello --> ''{{world}}'' {{<includeonly>subst:</includeonly>How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
12815 * <!-- Hello --> ''{{world}}'' {{subst:How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
12819 Play a bit with r67090 and bug 3158
12823 <div style="width:50% !important"> </div>
12824 <div style="width:50% !important"> </div>
12825 <div style="width:50% !important"> </div>
12826 <div style="border : solid;"> </div>
12828 <div style="width:50% !important"> </div>
12829 <div style="width:50% !important"> </div>
12830 <div style="width:50% !important"> </div>
12831 <div style="border : solid;"> </div>
12836 HTML5 data attributes
12838 <span data-foo="bar">Baz</span>
12839 <p data-abc-def_hij="">Quuz</p>
12841 <p><span data-foo="bar">Baz</span>
12843 <p data-abc-def_hij="">Quuz</p>
12848 percent-encoding and + signs in internal links (Bug 26410)
12850 [[User:+%]] [[Page+title%]]
12851 [[%+]] [[%+|%20]] [[%+ ]] [[%+r]]
12852 [[%]] [[+]] [[image:%+abc%39|foo|[[bar]]]]
12853 [[%33%45]] [[%33%45+]]
12855 <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>
12856 <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>
12857 <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>
12858 <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>
12863 Special characters in embedded file links (bug 27679)
12865 [[File:Contains & ampersand.jpg]]
12866 [[File:Does not exist.jpg|Title with & ampersand]]
12868 <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>
12869 <a href="/index.php?title=Special:Upload&wpDestFile=Does_not_exist.jpg" class="new" title="File:Does not exist.jpg">Title with & ampersand</a>
12875 Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)
12877 Text's been normalized?
12879 <p>Text's been normalized?
12884 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate free external links
12886 http://www.example.org/ <-- U+3000 (vim: ^Vu3000)
12888 <p><a rel="nofollow" class="external free" href="http://www.example.org/">http://www.example.org/</a> <-- U+3000 (vim: ^Vu3000)
12893 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links
12895 [http://www.example.org/ ideograms]
12897 <p><a rel="nofollow" class="external text" href="http://www.example.org/">ideograms</a>
12902 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate external images links
12904 http://www.example.org/pic.png <-- U+3000 (vim: ^Vu3000)
12906 <p><img src="http://www.example.org/pic.png" alt="pic.png" /> <-- U+3000 (vim: ^Vu3000)
12930 Bug 31098 Template which includes system messages which includes the template
12934 <p><span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
12935 <span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
12940 Bug31490 Turkish: ucfirst 'blah'
12951 Bug31490 Turkish: ucfirst 'ix'
12962 Bug31490 Turkish: lcfirst 'BLAH'
12973 Bug31490 Turkish: ucfırst (with a dotless i)
12979 <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>
12984 Bug31490 ucfırst (with a dotless i) with English language
12990 <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>
12995 Bug 26375: TOC with italics
12997 title=[[Main Page]]
13000 == ''Lost'' episodes ==
13002 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
13004 <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>
13007 <h2><span class="editsection">[<a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Lost episodes">edit</a>]</span> <span class="mw-headline" id="Lost_episodes"><i>Lost</i> episodes</span></h2>
13012 Bug 26375: TOC with bold
13014 title=[[Main Page]]
13017 == '''should be bold''' then normal text ==
13019 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
13021 <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>
13024 <h2><span class="editsection">[<a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: should be bold then normal text">edit</a>]</span> <span class="mw-headline" id="should_be_bold_then_normal_text"><b>should be bold</b> then normal text</span></h2>
13029 Bug 33845: Headings become cursive in TOC when they contain an image
13031 title=[[Main Page]]
13034 == Image [[Image:foobar.jpg]] ==
13036 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
13038 <li class="toclevel-1 tocsection-1"><a href="#Image"><span class="tocnumber">1</span> <span class="toctext">Image</span></a></li>
13041 <h2><span class="editsection">[<a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Image">edit</a>]</span> <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></h2>
13046 Bug 33845 (2): Headings become bold in TOC when they contain a blockquote
13048 title=[[Main Page]]
13051 == <blockquote>Quote</blockquote> ==
13053 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
13055 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
13058 <h2><span class="editsection">[<a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Quote">edit</a>]</span> <span class="mw-headline" id="Quote"><blockquote>Quote</blockquote></span></h2>
13063 Unclosed tags in TOC
13065 title=[[Main Page]]
13069 <small>Hanc marginis exiguitas non caperet.</small>
13072 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
13074 <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>
13077 <h2><span class="editsection">[<a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Proof: 2 < 3">edit</a>]</span> <span class="mw-headline" id="Proof:_2_.3C_3">Proof: 2 < 3</span></h2>
13078 <p><small>Hanc marginis exiguitas non caperet.</small>
13084 Multiple tags in TOC
13087 == <i>Foo</i> <b>Bar</b> ==
13089 == <i>Foo</i> <blockquote>Bar</blockquote> ==
13091 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
13093 <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>
13094 <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>
13097 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Foo Bar">edit</a>]</span> <span class="mw-headline" id="Foo_Bar"><i>Foo</i> <b>Bar</b></span></h2>
13098 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: Foo Bar">edit</a>]</span> <span class="mw-headline" id="Foo_Bar_2"><i>Foo</i> <blockquote>Bar</blockquote></span></h2>
13103 Tags with parameters in TOC
13106 == <sup class="in-h2">Hello</sup> ==
13108 == <sup class="a > b">Evilbye</sup> ==
13110 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
13112 <li class="toclevel-1 tocsection-1"><a href="#Hello"><span class="tocnumber">1</span> <span class="toctext"><sup>Hello</sup></span></a></li>
13113 <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>
13116 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: Hello">edit</a>]</span> <span class="mw-headline" id="Hello"><sup class="in-h2">Hello</sup></span></h2>
13117 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: b">Evilbye">edit</a>]</span> <span class="mw-headline" id="b.22.3EEvilbye"><sup> b">Evilbye</sup></span></h2>
13122 span tags with directionality in TOC
13125 == <span dir="ltr">C++</span> ==
13127 == <span dir="rtl">זבנג!</span> ==
13129 == <span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span> ==
13131 == <span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span> ==
13133 == <span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span> ==
13135 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
13137 <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>
13138 <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>
13139 <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>
13140 <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>
13141 <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>
13144 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: C++">edit</a>]</span> <span class="mw-headline" id="C.2B.2B"><span dir="ltr">C++</span></span></h2>
13145 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=2" title="Edit section: זבנג!">edit</a>]</span> <span class="mw-headline" id=".D7.96.D7.91.D7.A0.D7.92.21"><span dir="rtl">זבנג!</span></span></h2>
13146 <h2><span class="editsection">[<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> <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></h2>
13147 <h2><span class="editsection">[<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> <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></h2>
13148 <h2><span class="editsection">[<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> <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></h2>
13155 == {{int:headline_sample}} ==
13159 Bug 32057: Title needed when expanding <h> nodes.
13161 title=[[Main Page]]
13165 <h2><span class="editsection">[<a href="/index.php?title=Main_Page&action=edit&section=1" title="Edit section: Headline text">edit</a>]</span> <span class="mw-headline" id="Headline_text">Headline text</span></h2>
13170 Strip marker in urlencode
13172 {{urlencode:x<nowiki/>y}}
13173 {{urlencode:x<nowiki/>y|wiki}}
13174 {{urlencode:x<nowiki/>y|path}}
13201 Strip marker in formatNum
13203 {{formatnum:1<nowiki/>2}}
13204 {{formatnum:1<nowiki/>2|R}}
13212 Check noCommafy in formatNum
13216 {{formatnum:123456.78}}
13217 {{formatnum:123456.78|NOSEP}}
13225 Strip marker in grammar
13229 {{grammar:elative|foo<nowiki/>bar}}
13236 Strip marker in padleft
13238 {{padleft:|2|x<nowiki/>y}}
13245 Strip marker in padright
13247 {{padright:|2|x<nowiki/>y}}
13254 Strip marker in anchorencode
13256 {{anchorencode:x<nowiki/>y}}
13263 nowiki inside link inside heading (bug 18295)
13265 ==[[foo|x<nowiki>y</nowiki>z]]==
13267 <h2><span class="editsection">[<a href="/index.php?title=Parser_test&action=edit&section=1" title="Edit section: xyz">edit</a>]</span> <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></h2>
13272 new support for bdi element (bug 31817)
13274 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
13276 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
13281 Ignore pipe between table row attributes
13285 |- id=foo | style='color: red'
13293 <tr id="foo" style="color: red">
13300 Gallery override link with WikiLink (bug 34852)
13303 File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
13306 <ul class="gallery">
13307 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
13308 <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>
13309 <div class="gallerytext">
13319 Gallery override link with absolute external link (bug 34852)
13322 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
13325 <ul class="gallery">
13326 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
13327 <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>
13328 <div class="gallerytext">
13338 Gallery override link with malicious javascript (bug 34852)
13341 File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
13344 <ul class="gallery">
13345 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
13346 <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>
13347 <div class="gallerytext">
13357 Gallery with invalid title as link (bug 43964)
13360 File:foobar.jpg|link=<
13363 <ul class="gallery">
13364 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
13365 <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>
13366 <div class="gallerytext">
13374 Language parser function
13383 Padleft and padright as substr
13385 {{padleft:|3|abcde}}
13386 {{padright:|3|abcde}}
13394 Bug 34939 - Case insensitive link parsing ([HttP://])
13396 [HttP://MediaWiki.Org/]
13398 <p><a rel="nofollow" class="external autonumber" href="HttP://MediaWiki.Org/">[1]</a>
13403 Bug 34939 - Case insensitive link parsing ([HttP:// title])
13405 [HttP://MediaWiki.Org/ MediaWiki]
13407 <p><a rel="nofollow" class="external text" href="HttP://MediaWiki.Org/">MediaWiki</a>
13412 Bug 34939 - Case insensitive link parsing (HttP://)
13414 HttP://MediaWiki.Org/
13416 <p><a rel="nofollow" class="external free" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a>
13421 ### Parsoids-specific tests
13422 ### Parsoid-PHP parser incompatibilities
13425 1. SOL-sensitive wikitext tokens as template-args
13439 #### The following section of tests are primarily to test
13440 #### wikitext escaping capabilities of Parsoid.
13441 #### A lot of the tests are disabled for the PHP parser either
13442 #### because of minor newline diffs or other reasons.
13443 #### As Parsoid serializer can handle newlines and other HTML
13444 #### more robustly, some of these tests might get reenabled
13445 #### for the PHP parser.
13447 #### --------------- Headings ---------------
13449 #### 1. Nested inside html <h1>=foo=</h1>
13450 #### 2. Outside heading nest on a single line <h1>foo</h1>*bar
13451 #### 3. Nested inside html with wikitext split by html tags
13452 #### 4. No escape needed
13453 #### 5. Empty headings <h1></h1>
13454 #### 6. Heading chars in SOL context
13455 #### ----------------------------------------
13457 Headings: 0. Unnested
13459 <nowiki>=foo=</nowiki>
13461 <nowiki>=foo</nowiki>''a''=
13464 </p><p>=foo<i>a</i>=
13469 Headings: 1. Nested inside html
13473 =<nowiki>=foo=</nowiki>=
13474 ==<nowiki>=foo=</nowiki>==
13475 ===<nowiki>=foo=</nowiki>===
13476 ====<nowiki>=foo=</nowiki>====
13477 =====<nowiki>=foo=</nowiki>=====
13478 ======<nowiki>=foo=</nowiki>======
13489 Headings: 2. Outside heading nest on a single line <h1>foo</h1>*bar
13494 <nowiki>*bar</nowiki>
13498 <nowiki>=bar=</nowiki>
13506 Headings: 3. Nested inside html with wikitext split by html tags
13510 =<nowiki>=</nowiki>'''bold'''foo==
13512 <h1>=<b>bold</b>foo=</h1>
13516 Headings: 4. No escaping needed (testing just h1 and h2)
13531 <h1><i>=</i>foo=</h1>
13536 Headings: 5. Empty headings
13540 =<nowiki></nowiki>=
13541 ==<nowiki></nowiki>==
13542 ===<nowiki></nowiki>===
13543 ====<nowiki></nowiki>====
13544 =====<nowiki></nowiki>=====
13545 ======<nowiki></nowiki>======
13556 Headings: 6. Heading chars in SOL context
13560 <!--cmt--><nowiki>=h1=</nowiki>
13566 #### --------------- Lists ---------------
13567 #### 0. Outside nests (*foo, etc.)
13568 #### 1. Nested inside html <ul><li>*foo</li></ul>
13569 #### 2. Inside definition lists
13570 #### 3. Only bullets at start should be escaped
13571 #### 4. No escapes needed
13572 #### 5. No unnecessary escapes
13573 #### 6. Escape bullets in SOL position
13574 #### 7. Escape bullets in a multi-line context
13575 #### ----------------------------------------
13578 Lists: 0. Outside nests
13580 <nowiki>*foo</nowiki>
13582 <nowiki>#foo</nowiki>
13590 Lists: 1. Nested inside html
13592 *<nowiki>*foo</nowiki>
13594 *<nowiki>#foo</nowiki>
13596 *<nowiki>:foo</nowiki>
13598 *<nowiki>;foo</nowiki>
13600 #<nowiki>*foo</nowiki>
13602 #<nowiki>#foo</nowiki>
13604 #<nowiki>:foo</nowiki>
13606 #<nowiki>;foo</nowiki>
13628 Lists: 2. Inside definition lists
13630 ;<nowiki>;foo</nowiki>
13632 ;<nowiki>:foo</nowiki>
13634 ;<nowiki>:foo</nowiki>
13637 :<nowiki>:foo</nowiki>
13652 Lists: 3. Only bullets at start of text should be escaped
13654 *<nowiki>*foo*bar</nowiki>
13656 *<nowiki>*foo</nowiki>''it''*bar
13660 <ul><li>*foo<i>it</i>*bar
13666 Lists: 4. No escapes needed
13678 <ul><li><i>foo</i>*bar
13680 <ul><li><a href="Foo" rel="mw:WikiLink">Foo</a>: bar
13685 Lists: 5. No unnecessary escapes
13687 * bar <span><nowiki>[[foo]]</nowiki></span>
13689 *=bar <span><nowiki>[[foo]]</nowiki></span>
13691 *[[bar <span><nowiki>[[foo]]</nowiki></span>
13693 *<nowiki>]]bar </nowiki><span><nowiki>[[foo]]</nowiki></span>
13695 *=bar <span>foo]]</span>=
13697 <ul><li> bar <span>[[foo]]</span>
13699 <ul><li>=bar <span>[[foo]]</span>
13701 <ul><li>[[bar <span>[[foo]]</span>
13703 <ul><li>]]bar <span>[[foo]]</span>
13705 <ul><li>=bar <span>foo]]</span>=
13711 Lists: 6. Escape bullets in SOL position
13715 <!--cmt--><nowiki>*foo</nowiki>
13722 Lists: 7. Escape bullets in a multi-line context
13732 #### --------------- HRs ---------------
13733 #### 1. Single line
13734 #### -----------------------------------
13737 HRs: 1. Single line
13742 <nowiki>----</nowiki>
13744 <nowiki>=foo=</nowiki>
13746 <nowiki>*foo</nowiki>
13753 #### --------------- Tables ---------------
13754 #### 1a. Simple example
13755 #### 1b. No escaping needed (!foo)
13756 #### 1c. No escaping needed (|foo)
13757 #### 1d. No escaping needed (|}foo)
13759 #### 2a. Nested in td (<td>foo|bar</td>)
13760 #### 2b. Nested in td (<td>foo||bar</td>)
13761 #### 2c. Nested in td -- no escaping needed(<td>foo!!bar</td>)
13763 #### 3a. Nested in th (<th>foo!bar</th>)
13764 #### 3b. Nested in th (<th>foo!!bar</th>)
13765 #### 3c. Nested in th -- no escaping needed(<th>foo||bar</th>)
13769 #### 4c. No escaping needed
13770 #### --------------------------------------
13773 Tables: 1a. Simple example
13784 Tables: 1b. No escaping needed
13793 Tables: 1c. No escaping needed
13802 Tables: 1d. No escaping needed
13811 Tables: 2a. Nested in td
13816 |<nowiki>foo|bar</nowiki>
13826 Tables: 2b. Nested in td
13831 |<nowiki>foo||bar</nowiki>
13832 |''it''<nowiki>foo||bar</nowiki>
13837 </td><td><i>it</i>foo||bar
13843 Tables: 2c. Nested in td -- no escaping needed
13858 Tables: 3a. Nested in th
13873 Tables: 3b. Nested in th
13878 !<nowiki>foo!!bar</nowiki>
13888 Tables: 3c. Nested in th -- no escaping needed
13903 Tables: 4a. Escape -
13911 |<nowiki>-bar</nowiki>
13915 <tr><th>-bar</th></tr>
13916 <tr><td>-bar</td></tr>
13921 Tables: 4b. Escape +
13929 |<nowiki>+bar</nowiki>
13933 <tr><th>+bar</th></tr>
13934 <tr><td>+bar</td></tr>
13939 Tables: 4c. No escaping needed
13953 <tr><td>foo-bar</td><td>foo+bar</td></tr>
13954 <tr><td><i>foo</i>-bar</td><td><i>foo</i>+bar</td></tr>
13959 Tables: 4d. No escaping needed
13975 #### --------------- Links ---------------
13976 #### 1. Quote marks in link text
13977 #### 2. Wikilinks: Escapes needed
13978 #### 3. Wikilinks: No escapes needed
13979 #### 4. Extlinks: Escapes needed
13980 #### 5. Extlinks: No escapes needed
13981 #### --------------------------------------
13983 Links 1. Quote marks in link text
13987 [[Foo|<nowiki>Foo''boo''</nowiki>]]
13989 <a rel="mw:WikiLink" href="Foo">Foo''boo''</a>
13993 Links 2. WikiLinks: Escapes needed
13997 [[Foo|<nowiki>[Foobar]</nowiki>]]
13998 [[Foo|<nowiki>Foobar]</nowiki>]]
13999 [[Foo|<nowiki>x [Foobar] x</nowiki>]]
14000 [[Foo|<nowiki>x [http://google.com g] x</nowiki>]]
14001 [[Foo|<nowiki>[[Bar]]</nowiki>]]
14002 [[Foo|<nowiki>x [[Bar]] x</nowiki>]]
14003 [[Foo|<nowiki>|Bar</nowiki>]]
14005 <a href="Foo" rel="mw:WikiLink">[Foobar]</a>
14006 <a href="Foo" rel="mw:WikiLink">Foobar]</a>
14007 <a href="Foo" rel="mw:WikiLink">x [Foobar] x</a>
14008 <a href="Foo" rel="mw:WikiLink">x [http://google.com g] x</a>
14009 <a href="Foo" rel="mw:WikiLink">[[Bar]]</a>
14010 <a href="Foo" rel="mw:WikiLink">x [[Bar]] x</a>
14011 <a href="Foo" rel="mw:WikiLink">|Bar</a>
14015 Links 3. WikiLinks: No escapes needed
14022 <a href="Foo" rel="mw:WikiLink">[Foobar</a>
14023 <a href="Foo" rel="mw:WikiLink">foo|bar</a>
14027 Links 4. ExtLinks: Escapes needed
14031 [http://google.com <nowiki>[google]</nowiki>]
14032 [http://google.com <nowiki>google]</nowiki>]
14034 <a href="http://google.com" rel="mw:ExtLink">[google]</a>
14035 <a href="http://google.com" rel="mw:ExtLink">google]</a>
14039 Links 5. ExtLinks: No escapes needed
14043 [http://google.com [google]
14045 <a href="http://google.com" rel="mw:ExtLink">[google</a>
14048 #### --------------- Quotes ---------------
14049 #### 1. Quotes inside <b> and <i>
14050 #### 2. Link fragments separated by <i> and <b> tags
14051 #### 3. Link fragments inside <i> and <b>
14052 #### --------------------------------------
14054 1. Quotes inside <b> and <i>
14056 ''<nowiki>'foo'</nowiki>''
14057 ''<nowiki>''foo''</nowiki>''
14058 ''<nowiki>'''foo'''</nowiki>''
14059 '''<nowiki>'foo'</nowiki>'''
14060 '''<nowiki>''foo''</nowiki>'''
14061 '''<nowiki>'''foo'''</nowiki>'''
14062 '''<nowiki>foo'</nowiki>''<nowiki>bar'</nowiki>''baz'''
14070 <b>foo'<i>bar'</i>baz</b>
14075 2. Link fragments separated by <i> and <b> tags
14077 [[''foo''<nowiki>hello]]</nowiki>
14079 [['''foo'''<nowiki>hello]]</nowiki>
14081 <p>[[<i>foo</i>hello]]
14082 </p><p>[[<b>foo</b>hello]]
14087 2. Link fragments inside <i> and <b>
14088 (FIXME: Escaping one or both of [[ and ]] is also acceptable --
14089 this is one of the shortcomings of this format)
14091 ''[[foo''<nowiki>]]</nowiki>
14093 '''[[foo'''<nowiki>]]</nowiki>
14096 </p><p><b>[[foo</b>]]
14100 #### --------------- Paragraphs ---------------
14101 #### 1. No unnecessary escapes
14102 #### --------------------------------------
14105 1. No unnecessary escapes
14107 bar <span><nowiki>[[foo]]</nowiki></span>
14109 =bar <span><nowiki>[[foo]]</nowiki></span>
14111 [[bar <span><nowiki>[[foo]]</nowiki></span>
14113 <nowiki>]]bar </nowiki><span><nowiki>[[foo]]</nowiki></span>
14115 <nowiki>=bar </nowiki><span>foo]]</span>=
14117 <p>bar <span>[[foo]]</span>
14118 </p><p>=bar <span>[[foo]]</span>
14119 </p><p>[[bar <span>[[foo]]</span>
14120 </p><p>]]bar <span>[[foo]]</span>
14121 </p><p>=bar <span>foo]]</span>=
14125 #### --------------- PRE ------------------
14126 #### 1. Leading space in SOL context should be escaped
14127 #### --------------------------------------
14129 1. Leading space in SOL context should be escaped
14133 <nowiki> foo</nowiki>
14134 <!--cmt--><nowiki> foo</nowiki>
14141 #### --------------- HTML tags ---------------
14144 #### 3. multi-line html tag
14145 #### --------------------------------------
14151 <a href="http://google.com">google</a>
14153 <a href="http://google.com">google</a>
14159 <nowiki><div>foo</div>
14160 <div style="color:red">foo</div></nowiki>
14162 <p><div>foo</div>
14163 <div style="color:red">foo</div>
14168 3. multi-line html tag
14180 #### --------------- Others ---------------
14184 <nowiki>foo</nowiki>
14186 <p><nowiki>foo</nowiki>
14191 Tag-like HTML structures are passed through as text
14213 </p><p>1<d e>f
14218 # This fails in the PHP parser (see bug 40670,
14219 # https://bugzilla.wikimedia.org/show_bug.cgi?id=40670), so disabled for it.
14221 Tag names followed by punctuation should not be recognized as tags
14227 <p><s.ome> text
14232 HTML tag with necessary entities in attributes
14234 <span title="&amp;">foo</span>
14236 <p><span title="&amp;">foo</span>
14241 HTML tag with 'unnecessary' entity encoding in attributes
14243 <span title="&">foo</span>
14245 <p><span title="&">foo</span>
14250 HTML tag with broken attribute value quoting
14252 <span title="Hello world>Foo</span>
14254 <p><span>Foo</span>
14259 Parsoid-only: HTML tag with broken attribute value quoting
14263 <span title="Hello world>Foo</span>
14265 <p><span title="Hello world">Foo</span>
14270 Table with broken attribute value quoting
14273 | title="Hello world|Foo
14284 Table with broken attribute value quoting on consecutive lines
14287 | title="Hello world|Foo
14288 | style="color:red|Bar
14301 Parsoid-only: Table with broken attribute value quoting on consecutive lines
14306 | title="Hello world|Foo
14307 | style="color:red|Bar
14312 <td title="Hello world">Foo
14313 </td><td style="color: red">Bar
14319 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
14329 Parsoid-only: Don't wrap broken template tags in <nowiki> on wt2wt (Bug 42353)
14339 Accept empty td cell attribute
14342 | align="center" | foo || |
14347 <td align="center"> foo </td>
14354 Non-empty attributes in th-cells
14357 ! Foo !! style="color: red" | Bar
14363 <th style="color: red"> Bar
14369 Accept empty attributes in th-cells
14384 Empty table rows go away
14405 ### Parsoid-centric tests for testing RTing of inter-element separators
14406 ### Edge cases not tested by existing parser tests and specific to
14407 ### Parsoid-specific serialization strategies.
14411 RT-ed inter-element separators should be valid separators
14424 Trailing newlines in a deep dom-subtree that ends a wikitext line should be migrated out
14425 (Parsoid-only since PHP parser relies on Tidy for correct output)
14441 Empty TD followed by TD with tpl-generated attribute
14446 |{{echo|style='color:red'}}|foo
14460 Empty TR followed by a template-generated TR
14461 (Parsoid-specific since PHP parser doesn't handle this mixed tbl-wikitext)
14467 {{echo|<tr><td>foo</td></tr>}}
14475 <td>foo</td></tr></tbody></table>
14479 Multi-line image caption generated by templates with/without trailing newlines
14483 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}]]
14484 [[File:foo.jpg|thumb|300px|foo\n{{echo|A}}\n{{echo|B}}\n{{echo|C}}\n\n]]
14486 <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>
14487 <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>
14496 Try for 100% code coverage