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
170 http://fr.wikipedia.org/wiki/🍺
171 <!-- EasterEgg we love beer, better be able be able to link to it -->
173 <p><a rel="nofollow" class="external free" href="http://fr.wikipedia.org/wiki/🍺">http://fr.wikipedia.org/wiki/🍺</a>
193 * plain''italic''plain
194 * plain''italic''plain''italic''plain
195 * plain'''bold'''plain
196 * plain'''bold'''plain'''bold'''plain
197 * plain''italic''plain'''bold'''plain
198 * plain'''bold'''plain''italic''plain
199 * plain''italic'''bold-italic'''italic''plain
200 * plain'''bold''bold-italic''bold'''plain
201 * plain'''''bold-italic'''italic''plain
202 * plain'''''bold-italic''bold'''plain
203 * plain''italic'''bold-italic'''''plain
204 * plain'''bold''bold-italic'''''plain
205 * plain l'''italic''plain
206 * plain l''''bold''' plain
209 </li><li> plain<i>italic</i>plain
210 </li><li> plain<i>italic</i>plain<i>italic</i>plain
211 </li><li> plain<b>bold</b>plain
212 </li><li> plain<b>bold</b>plain<b>bold</b>plain
213 </li><li> plain<i>italic</i>plain<b>bold</b>plain
214 </li><li> plain<b>bold</b>plain<i>italic</i>plain
215 </li><li> plain<i>italic<b>bold-italic</b>italic</i>plain
216 </li><li> plain<b>bold<i>bold-italic</i>bold</b>plain
217 </li><li> plain<i><b>bold-italic</b>italic</i>plain
218 </li><li> plain<b><i>bold-italic</i>bold</b>plain
219 </li><li> plain<i>italic<b>bold-italic</b></i>plain
220 </li><li> plain<b>bold<i>bold-italic</i></b>plain
221 </li><li> plain l'<i>italic</i>plain
222 </li><li> plain l'<b>bold</b> plain
228 ### 2-quote opening sequence tests
231 Italics and bold: 2-quote opening sequence: (2,2)
241 Italics and bold: 2-quote opening sequence: (2,3)
251 Italics and bold: 2-quote opening sequence: (2,4)
261 Italics and bold: 2-quote opening sequence: (2,5)
271 ### 3-quote opening sequence tests
275 Italics and bold: 3-quote opening sequence: (3,2)
285 Italics and bold: 3-quote opening sequence: (3,3)
295 Italics and bold: 3-quote opening sequence: (3,4)
305 Italics and bold: 3-quote opening sequence: (3,5)
315 ### 4-quote opening sequence tests
319 Italics and bold: 4-quote opening sequence: (4,2)
329 Italics and bold: 4-quote opening sequence: (4,3)
339 Italics and bold: 4-quote opening sequence: (4,4)
349 Italics and bold: 4-quote opening sequence: (4,5)
359 ### 5-quote opening sequence tests
363 Italics and bold: 5-quote opening sequence: (5,2)
373 Italics and bold: 5-quote opening sequence: (5,3)
383 Italics and bold: 5-quote opening sequence: (5,4)
387 <p><i><b>foo'</b></i>
393 Italics and bold: 5-quote opening sequence: (5,5)
402 ### multiple quote sequences in a line
405 Italics and bold: multiple quote sequences: (2,4,2)
409 <p><i>foo'<b>bar</b></i>
415 Italics and bold: multiple quote sequences: (2,4,3)
419 <p><i>foo'<b>bar</b></i>
425 Italics and bold: multiple quote sequences: (2,4,4)
429 <p><i>foo'<b>bar'</b></i>
435 Italics and bold: multiple quote sequences: (3,4,2)
445 Italics and bold: multiple quote sequences: (3,4,3)
454 ### other quote tests
457 Italics and bold: other quote tests: (2,3,5)
459 ''this is about '''foo's family'''''
461 <p><i>this is about <b>foo's family</b></i>
467 Italics and bold: other quote tests: (2,(3,3),2)
469 ''this is about '''foo's''' family''
471 <p><i>this is about <b>foo's</b> family</i>
477 Italics and bold: other quote tests: (3,2,3,2)
479 '''this is about ''foo'''s family''
481 <p><b>this is about <i>foo</i></b><i>s family</i>
487 Italics and bold: other quote tests: (3,2,3,3)
489 '''this is about ''foo'''s family'''
491 <p>'<i>this is about </i>foo<b>s family</b>
497 Italics and bold: other quote tests: (3,(2,2),3)
499 '''this is about ''foo's'' family'''
501 <p><b>this is about <i>foo's</i> family</b>
507 Italicized possessive
509 The ''[[Main Page]]'''s talk page.
511 <p>The <i><a href="/wiki/Main_Page" title="Main Page">Main Page</a>'</i>s talk page.
520 Non-html5 tags should be accepted
522 <center>''foo''</center>
525 <strike>''foo''</strike>
528 <center><i>foo</i></center>
529 <p><big><i>foo</i></big>
530 <font><i>foo</i></font>
531 <strike><i>foo</i></strike>
537 ### <nowiki> test cases
541 <nowiki> unordered list
543 <nowiki>* This is not an unordered list item.</nowiki>
545 <p>* This is not an unordered list item.
552 <nowiki>Lorem ipsum dolor
573 :There is not nowiki.
574 :There is <nowiki>nowiki</nowiki>.
576 #There is not nowiki.
577 #There is <nowiki>nowiki</nowiki>.
579 *There is not nowiki.
580 *There is <nowiki>nowiki</nowiki>.
582 <dl><dd>There is not nowiki.
583 </dd><dd>There is nowiki.
585 <ol><li>There is not nowiki.
586 </li><li>There is nowiki.
588 <ul><li>There is not nowiki.
589 </li><li>There is nowiki.
595 Entities inside <nowiki>
597 <nowiki><</nowiki>
608 Comments and Indent-Pre
610 <!-- comment 1 --> asdf
612 <!-- comment 1 --> asdf
615 <!-- comment 1 --> asdf
616 <!-- comment 2 -->xyz
618 <!-- comment 1 --> asdf
619 <!-- comment 2 --> xyz
675 asdf<!-- comment 1 -->jkl
685 <!-- foo --> b <!-- bar -->
699 <!-- returns a single newline, not nothing, since the newline after > is not stripped -->
705 Comment semantics and delimiters
707 <!-- --><!----><!-----><!------>
713 Comment semantics and delimiters, redux
715 <!-- In SGML every "foo" here would actually show up in the text -- foo -- bar
716 -- foo -- funky huh? ... -->
722 Comment semantics and delimiters: directors cut
724 <!-- ... However we like to keep things simple and somewhat XML-ish so we eat
725 everything starting with < followed by !-- until the first -- and > we see,
726 that wouldn't be valid XML however, since in XML -- has to terminate a comment
734 Comment semantics: nesting
736 <!--<!-- no, we're not going to do anything fancy here -->-->
743 Comment semantics: unclosed comment at end
745 <!--This comment will run out to the end of the document
751 Comment in template title
760 Comment on its own line post-expand
772 Comment on its own line post-expand with non-significant whitespace
784 ### paragraph wraping tests
798 Block tag on one line
810 Block tag on both lines
822 Multiple lines without block tags
840 Empty lines between lines with block tags
870 ### Preformatted text
879 And a [[Main Page|link]]
885 And a <a href="/wiki/Main_Page" title="Main Page">link</a>
890 Ident preformatting with inline content
901 <pre> with <nowiki> inside (compatibility with 1.6 and earlier)
918 Regression with preformatted in <center>
931 # Expected output in the following test is not really expected (there should be
932 # <pre> in the output) -- it's only testing for well-formedness.
934 Bug 6200: Preformatted in <blockquote>
947 <pre> with attributes (bug 3202)
949 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
951 <pre style="background: blue; color:white">Bluescreen of WikiDeath</pre>
956 <pre> with width attribute (bug 3202)
958 <pre width="8">Narrow screen goodies</pre>
960 <pre width="8">Narrow screen goodies</pre>
965 <pre> with forbidden attribute (bug 3202)
967 <pre width="8" onmouseover="alert(document.cookie)">Narrow screen goodies</pre>
969 <pre width="8">Narrow screen goodies</pre>
974 Entities inside <pre>
983 <pre> with forbidden attribute values (bug 3202)
985 <pre width="8" style="border-width: expression(alert(document.cookie))">Narrow screen goodies</pre>
987 <pre width="8" style="/* insecure input */">Narrow screen goodies</pre>
992 <nowiki> inside <pre> (bug 13238)
1000 <pre><nowiki><nowiki></nowiki>Foo<nowiki></nowiki></nowiki></pre>
1008 <pre><nowiki>Foo</nowiki></pre>
1013 <nowiki> and <pre> preference (first one wins)
1044 </pre> inside nowiki
1046 <nowiki></pre></nowiki>
1053 Templates: Indent-Pre: 1a. Templates that break a line should suppress <pre>
1061 Templates: Indent-Pre: 1b. Templates that break a line should suppress <pre>
1071 Templates: Indent-Pre: 1c: Wrapping should be based on expanded content
1083 Templates: Indent-Pre: 1d: Wrapping should be based on expanded content
1104 Templates: Indent-Pre: 1e. Wrapping should be based on expanded content
1108 {{echo| foo}}{{echo| bar}}
1113 {{echo|<!--cmt--> foo}}
1115 <!--cmt-->{{echo| foo}}
1117 {{echo|{{echo| }}bar}}
1135 Templates: Indent-Pre: 1f: Wrapping should be based on expanded content
1172 Templates: Single-line variant of parameter whitespace stripping test
1178 {{echo|{{echo| a}}}}
1180 {{echo|1={{echo| a}}}}
1193 Templates: Strip whitespace from named parameters, but not positional ones
1221 ### Parsoid-centric tests for testing RT edge cases for pre
1225 1a. Indent-Pre and Comments
1238 1b. Indent-Pre and Comments
1251 1c. Indent-Pre and Comments
1264 2a. Indent-Pre and tables
1285 2b. Indent-Pre and tables
1301 2c. Indent-Pre and tables (bug 42252)
1318 3a. Indent-Pre and block tags (single-line html)
1326 <pre><span> foo </span>
1331 3b. Indent-Pre and block tags (pre-content on separate line)
1383 4. Multiple spaces at start-of-line
1402 5. White-space in indent-pre
1403 NOTE: the white-space char on 2nd line is significant
1416 ### HTML-pre (some to spec PHP parser behavior and some Parsoid-RT-centric)
1420 HTML-pre: 1. embedded newlines
1456 HTML-pre: 2: indented text
1469 HTML-pre: 3: other wikitext
1490 ### Definition lists
1497 <dl><dt> name </dt><dd> Definition
1503 Definition list for indentation only
1507 <dl><dd> Indented text
1513 Definition list with no space
1517 <dl><dt>name</dt><dd>Definition
1523 Definition list with URL link
1525 ; http://example.com/ : definition
1527 <dl><dt> <a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> </dt><dd> definition
1533 Definition list with bracketed URL link
1535 ;[http://www.example.com/ Example]:Something about it
1537 <dl><dt><a rel="nofollow" class="external text" href="http://www.example.com/">Example</a></dt><dd>Something about it
1543 Definition list with wikilink containing colon
1545 ; [[Help:FAQ]]: The least-read page on Wikipedia
1547 <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
1552 # At Brion's and JeLuF's insistence... :)
1554 Definition list with news link containing colon
1556 ; news:alt.wikipedia.rox: This isn't even a real newsgroup!
1558 <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!
1564 Malformed definition list with colon
1566 ; news:alt.wikipedia.rox -- don't crash or enter an infinite loop
1568 <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
1574 Definition lists: colon in external link text
1576 ; [http://www.wikipedia2.org/ Wikipedia : The Next Generation]: OK, I made that up
1578 <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
1584 Definition lists: colon in HTML attribute
1586 ;<b style="display: inline">bold</b>
1588 <dl><dt><b style="display: inline">bold</b>
1594 Definition lists: self-closed tag
1596 ;one<br/>two : two-line fun
1598 <dl><dt>one<br />two </dt><dd> two-line fun
1604 Bug 11748: Literal closing tags
1608 <dd>test test test test test</dd>
1610 <dd>test test test test test</dd>
1615 <dd>test test test test test</dd>
1617 <dd>test test test test test</dd>
1623 Definition and unordered list using wiki syntax nested in unordered list using html tags.
1626 ; term : description
1632 <dl><dt> term </dt><dd> description
1643 Definition list with empty definition and following paragraph
1648 <dl><dt> term</dt><dd>
1655 Nested definition lists using html syntax
1672 Definition Lists: No nesting: Multiple dd's
1686 Definition Lists: Indentation: Regular
1702 Definition Lists: Indentation: Missing 1st level
1716 Definition Lists: Indentation: Multi-level indent
1720 <dl><dd><dl><dd><dl><dd>i3
1728 Definition Lists: Hacky use to indent tables
1735 should be left alone
1737 <dl><dd><dl><dd><table>
1742 </td></tr></table></dd></dl></dd></dl>
1744 should be left alone
1747 ## The PHP parser treats : items (dd) without a corresponding ; item (dt)
1748 ## as an empty dt item. It also ignores all but the last ";" when followed
1749 ## by ":" later on. So, ";" are not ignored in ";;;t3" but are ignored in
1750 ## ";;;t3 :d1". So, PHP parser behavior is a little inconsistent wrt multiple
1753 ## Ex: ";;t2 ::d2" is transformed into:
1765 ## But, Parsoid treats "; :" as a tight atomic unit and excess ":" as plain text
1766 ## So, the same wikitext above (;;t2 ::d2) is transformed into:
1777 ## All Parsoid only definition list tests have this difference.
1779 ## See also: https://bugzilla.wikimedia.org/show_bug.cgi?id=6569
1780 ## and http://lists.wikimedia.org/pipermail/wikitext-l/2011-November/000483.html
1783 Table / list interaction: indented table with lists in table contents
1805 </td></tr></table></dd></dl>
1810 Table / list interaction: lists nested in tables nested in indented lists
1835 </td></tr></table></dd></dl>
1843 Definition Lists: Nesting: Multi-level (Parsoid only)
1873 Definition Lists: Nesting: Test 2 (Parsoid only)
1893 Definition Lists: Nesting: Test 3 (Parsoid only)
1921 Definition Lists: Nesting: Test 4
1926 <dl><dd><dl><dd><dl><dt>t3
1936 Definition Lists: Mixed Lists: Test 1
1942 <dl><dd><dl><dt><ul><li> foo
1954 Definition Lists: Mixed Lists: Test 2
1968 Definition Lists: Mixed Lists: Test 3
1973 <ul><li><dl><dd><dl><dd><dl><dd> d1
1984 Definition Lists: Mixed Lists: Test 4
1989 <ul><li><dl><dt>d1 </dt><dd>d2
1990 </dd><dt>d3 </dt><dd>d4
1998 Definition Lists: Mixed Lists: Test 5
2013 Definition Lists: Mixed Lists: Test 6
2018 <ol><li><ul><li><dl><dd>d1
2030 Definition Lists: Mixed Lists: Test 7
2044 Definition Lists: Mixed Lists: Test 8
2060 Definition Lists: Mixed Lists: Test 9
2064 <ul><li><dl><dt>foo </dt><dd>bar
2072 Definition Lists: Mixed Lists: Test 10
2076 <ul><li><ol><li><dl><dt>foo </dt><dd>bar
2085 Definition Lists: Mixed Lists: Test 11
2090 <ul><li><ol><li><ul><li><ol><li><dl><dt>foo </dt><dd><ul><li><dl><dt><dl><dt>bar
2095 <dl><dt>boo </dt><dd>baz
2106 Definition Lists: Weird Ones: Test 1
2108 *#;*::;; foo : bar (who uses this?)
2110 <ul><li><ol><li><dl><dt> foo </dt><dd><ul><li><dl><dd><dl><dd><dl><dt><dl><dt> bar (who uses this?)
2126 External links: non-bracketed
2128 Non-bracketed: http://example.com
2130 <p>Non-bracketed: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
2135 External links: numbered
2137 Numbered: [http://example.com]
2138 Numbered: [http://example.net]
2139 Numbered: [http://example.com]
2141 <p>Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[1]</a>
2142 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.net">[2]</a>
2143 Numbered: <a rel="nofollow" class="external autonumber" href="http://example.com">[3]</a>
2148 External links: specified text
2150 Specified text: [http://example.com link]
2152 <p>Specified text: <a rel="nofollow" class="external text" href="http://example.com">link</a>
2157 External links: trail
2159 Linktrails should not work for external links: [http://example.com link]s
2161 <p>Linktrails should not work for external links: <a rel="nofollow" class="external text" href="http://example.com">link</a>s
2166 External links: dollar sign in URL
2168 http://example.com/1$2345
2170 <p><a rel="nofollow" class="external free" href="http://example.com/1$2345">http://example.com/1$2345</a>
2175 External links: dollar sign in URL (named)
2177 [http://example.com/1$2345]
2179 <p><a rel="nofollow" class="external autonumber" href="http://example.com/1$2345">[1]</a>
2184 External links: open square bracket forbidden in URL (bug 4377)
2186 http://example.com/1[2345
2188 <p><a rel="nofollow" class="external free" href="http://example.com/1">http://example.com/1</a>[2345
2193 External links: open square bracket forbidden in URL (named) (bug 4377)
2195 [http://example.com/1[2345]
2197 <p><a rel="nofollow" class="external text" href="http://example.com/1">[2345</a>
2202 External links: nowiki in URL link text (bug 6230)
2204 [http://example.com/ <nowiki>''example site''</nowiki>]
2206 <p><a rel="nofollow" class="external text" href="http://example.com/">''example site''</a>
2211 External links: newline forbidden in text (bug 6230 regression check)
2213 [http://example.com/ first
2216 <p>[<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a> first
2222 External links: Pipe char between url and text
2224 [http://example.com | link]
2226 <p><a rel="nofollow" class="external text" href="http://example.com">| link</a>
2231 External links: protocol-relative URL in brackets
2233 [//example.com/ Test]
2235 <p><a rel="nofollow" class="external text" href="//example.com/">Test</a>
2240 External links: protocol-relative URL in brackets without text
2244 <p><a rel="nofollow" class="external autonumber" href="//example.com">[1]</a>
2249 External links: protocol-relative URL in free text is left alone
2253 <p>//example.com/Foo
2258 External links: protocol-relative URL in the middle of a word is left alone (bug 30269)
2260 foo//example.com/Foo
2262 <p>foo//example.com/Foo
2269 External image: http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2271 <p>External image: <img src="http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
2276 External image from https
2278 External image from https: https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png
2280 <p>External image from https: <img src="https://meta.wikimedia.org/upload/f/f1/Ncwikicol.png" alt="Ncwikicol.png" />
2285 Link to non-http image, no img tag
2287 Link to non-http image, no img tag: ftp://example.com/test.jpg
2289 <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>
2294 External links: terminating separator
2296 Terminating separator: http://example.com/thing,
2298 <p>Terminating separator: <a rel="nofollow" class="external free" href="http://example.com/thing">http://example.com/thing</a>,
2303 External links: intervening separator
2305 Intervening separator: http://example.com/1,2,3
2307 <p>Intervening separator: <a rel="nofollow" class="external free" href="http://example.com/1,2,3">http://example.com/1,2,3</a>
2312 External links: old bug with URL in query
2314 Old bug with URL in query: [http://example.com/thing?url=http://example.com link]
2316 <p>Old bug with URL in query: <a rel="nofollow" class="external text" href="http://example.com/thing?url=http://example.com">link</a>
2321 External links: old URL-in-URL bug, mixed protocols
2323 And again with mixed protocols: [ftp://example.com?url=http://example.com link]
2325 <p>And again with mixed protocols: <a rel="nofollow" class="external text" href="ftp://example.com?url=http://example.com">link</a>
2330 External links: URL in text
2332 URL in text: [http://example.com http://example.com]
2334 <p>URL in text: <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>
2339 External links: Clickable images
2341 ja-style clickable images: [http://example.com http://meta.wikimedia.org/upload/f/f1/Ncwikicol.png]
2343 <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>
2348 External links: raw ampersand
2350 Old & use: http://x&y
2352 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
2357 External links: encoded ampersand
2359 Old & use: http://x&y
2361 <p>Old & use: <a rel="nofollow" class="external free" href="http://x&y">http://x&y</a>
2366 External links: encoded equals (bug 6102)
2368 http://example.com/?foo=bar
2370 <p><a rel="nofollow" class="external free" href="http://example.com/?foo=bar">http://example.com/?foo=bar</a>
2375 External links: [raw ampersand]
2377 Old & use: [http://x&y]
2379 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
2384 External links: [encoded ampersand]
2386 Old & use: [http://x&y]
2388 <p>Old & use: <a rel="nofollow" class="external autonumber" href="http://x&y">[1]</a>
2393 External links: [encoded equals] (bug 6102)
2395 [http://example.com/?foo=bar]
2397 <p><a rel="nofollow" class="external autonumber" href="http://example.com/?foo=bar">[1]</a>
2402 External links: [IDN ignored character reference in hostname; strip it right off]
2404 [http://e‌xample.com/]
2406 <p><a rel="nofollow" class="external autonumber" href="http://example.com/">[1]</a>
2410 # FIXME: This test (the IDN characters in the text of a link) is an inconsistency.
2411 # Where an external link could easily circumvent the sanitization of the text of
2412 # a link like this (where an IDN-ignore character is in the URL somewhere), this
2413 # test demands a higher standard. That's a bit strange.
2417 # http://example.com -> [http://example.com|http://example.com]
2418 # [http://example.com|http://example.com] -> [http://example.com|http://example.com]
2420 # The first example is sanitized, but the second is not. Any security benefits
2421 # from this production are trivial to circumvent. Either remove this test and
2422 # let the parser(s) do their thing unaccosted, or fix the inconsistency and change
2423 # the test accordingly.
2428 External links: IDN ignored character reference in hostname; strip it right off
2430 http://e‌xample.com/
2432 <p><a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>
2437 External links: www.jpeg.org (bug 554)
2441 <p><a rel="nofollow" class="external free" href="http://www.jpeg.org">http://www.jpeg.org</a>
2446 External links: URL within URL (original bug 2)
2448 [http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp]
2450 <p><a rel="nofollow" class="external autonumber" href="http://www.unausa.org/newindex.asp?place=http://www.unausa.org/programs/mun.asp">[1]</a>
2455 BUG 361: URL inside bracketed URL
2457 [http://www.example.com/foo http://www.example.com/bar]
2459 <p><a rel="nofollow" class="external text" href="http://www.example.com/foo">http://www.example.com/bar</a>
2464 BUG 361: URL within URL, not bracketed
2466 http://www.example.com/foo?=http://www.example.com/bar
2468 <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>
2473 BUG 289: ">"-token in URL-tail
2475 http://www.example.com/<hello>
2477 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><hello>
2482 BUG 289: literal ">"-token in URL-tail
2484 http://www.example.com/<b>html</b>
2486 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a><b>html</b>
2491 BUG 289: ">"-token in bracketed URL
2493 [http://www.example.com/<hello> stuff]
2495 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><hello> stuff</a>
2500 BUG 289: literal ">"-token in bracketed URL
2502 [http://www.example.com/<b>html</b> stuff]
2504 <p><a rel="nofollow" class="external text" href="http://www.example.com/"><b>html</b> stuff</a>
2509 BUG 289: literal double quote at end of URL
2511 http://www.example.com/"hello"
2513 <p><a rel="nofollow" class="external free" href="http://www.example.com/">http://www.example.com/</a>"hello"
2518 BUG 289: literal double quote in bracketed URL
2520 [http://www.example.com/"hello" stuff]
2522 <p><a rel="nofollow" class="external text" href="http://www.example.com/">"hello" stuff</a>
2527 External links: multiple legal whitespace is fine, Magnus. Don't break it please. (bug 5081)
2529 [http://www.example.com test]
2531 <p><a rel="nofollow" class="external text" href="http://www.example.com">test</a>
2536 External links: link text with spaces
2538 [http://www.example.com a b c]
2539 [http://www.example.com ''a'' ''b'']
2541 <p><a rel="nofollow" class="external text" href="http://www.example.com">a b c</a>
2542 <a rel="nofollow" class="external text" href="http://www.example.com"><i>a</i> <i>b</i></a>
2547 External links: wiki links within external link (Bug 3695)
2549 [http://example.com [[wikilink]] embedded in ext link]
2551 <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>
2556 BUG 787: Links with one slash after the url protocol are invalid
2560 [http:/example.com title]
2562 <p>http:/example.com
2563 </p><p>[http:/example.com title]
2568 Bracketed external links with template-generated invalid target
2570 [{{echo|http:/example.com}} title]
2572 <p>[http:/example.com title]
2577 Bug 2702: Mismatched <i>, <b> and <a> tags are invalid
2579 ''[http://example.com text'']
2580 [http://example.com '''text]'''
2581 ''Something [http://example.com in italic'']
2582 ''Something [http://example.com mixed''''', even bold]'''
2583 '''''Now [http://example.com both''''']
2585 <p><a rel="nofollow" class="external text" href="http://example.com"><i>text</i></a>
2586 <a rel="nofollow" class="external text" href="http://example.com"><b>text</b></a>
2587 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>in italic</i></a>
2588 <i>Something </i><a rel="nofollow" class="external text" href="http://example.com"><i>mixed</i><b>, even bold</b></a>
2589 <i><b>Now </b></i><a rel="nofollow" class="external text" href="http://example.com"><i><b>both</b></i></a>
2595 Bug 4781: %26 in URL
2597 http://www.example.com/?title=AT%26T
2599 <p><a rel="nofollow" class="external free" href="http://www.example.com/?title=AT%26T">http://www.example.com/?title=AT%26T</a>
2603 # According to http://dev.w3.org/html5/spec/Overview.html#parsing-urls a plain
2604 # % is actually legal in HTML5. Any change in output would need testing though.
2606 Bug 4781, 5267: %25 in URL
2608 http://www.example.com/?title=100%25_Bran
2610 <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>
2615 Bug 4781, 5267: %28, %29 in URL
2617 http://www.example.com/?title=Ben-Hur_%281959_film%29
2619 <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>
2625 Bug 4781: %26 in autonumber URL
2627 [http://www.example.com/?title=AT%26T]
2629 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=AT%26T">[1]</a>
2634 Bug 4781, 5267: %26 in autonumber URL
2636 [http://www.example.com/?title=100%25_Bran]
2638 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=100%25_Bran">[1]</a>
2643 Bug 4781, 5267: %28, %29 in autonumber URL
2645 [http://www.example.com/?title=Ben-Hur_%281959_film%29]
2647 <p><a rel="nofollow" class="external autonumber" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">[1]</a>
2653 Bug 4781: %26 in bracketed URL
2655 [http://www.example.com/?title=AT%26T link]
2657 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=AT%26T">link</a>
2662 Bug 4781, 5267: %26 in bracketed URL
2664 [http://www.example.com/?title=100%25_Bran link]
2666 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=100%25_Bran">link</a>
2671 Bug 4781, 5267: %28, %29 in bracketed URL
2673 [http://www.example.com/?title=Ben-Hur_%281959_film%29 link]
2675 <p><a rel="nofollow" class="external text" href="http://www.example.com/?title=Ben-Hur_%281959_film%29">link</a>
2680 External link containing double-single-quotes in text '' (bug 4598 sanity check)
2682 Some [http://example.com/ pretty ''italics'' and stuff]!
2684 <p>Some <a rel="nofollow" class="external text" href="http://example.com/">pretty <i>italics</i> and stuff</a>!
2689 External link containing double-single-quotes in text embedded in italics (bug 4598 sanity check)
2691 ''Some [http://example.com/ pretty ''italics'' and stuff]!''
2693 <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>
2698 External link containing double-single-quotes with no space separating the url from text in italics
2700 [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]].]
2702 <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>
2707 URL-encoding in URL functions (single parameter)
2709 {{localurl:Some page|amp=&}}
2711 <p>/index.php?title=Some_page&amp=&
2716 URL-encoding in URL functions (multiple parameters)
2718 {{localurl:Some page|q=?&=&}}
2720 <p>/index.php?title=Some_page&q=?&amp=&
2727 http://example.com/index.php?foozoid%5B%5D=bar
2729 http://example.com/index.php?foozoid[]=bar
2731 <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>
2732 </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>
2737 IPv6 urls (bug 21261)
2741 http://[2404:130:0:1000::187:2]/index.php
2743 <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>
2748 Non-extlinks in brackets
2757 [{{echo|foo}} ''bar'']
2758 [{{echo|foo}}l's] errand
2759 [{{echo|foo}}l's errand]
2761 [url=http://example.com]
2774 [url=<a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>]
2785 Normal text. '''Bold text.''' Normal text. ''Italic text.''
2787 Normal text. '''''Bold italic text.''''' Normal text.
2789 <p>Normal text. <b>Bold text.</b> Normal text. <i>Italic text.</i>
2790 </p><p>Normal text. <i><b>Bold italic text.</b></i> Normal text.
2796 Unclosed and unmatched quotes
2798 '''''Bold italic text '''with bold deactivated''' in between.'''''
2800 '''''Bold italic text ''with italic deactivated'' in between.'''''
2804 ..spanning two paragraphs (should not work).'''
2806 '''Bold tag left open
2808 ''Italic tag left open
2812 <!-- Unmatching number of opening, closing tags: -->
2813 '''This year''''s election ''should'' beat '''last year''''s.
2815 ''Tom'''s car is bigger than ''Susan'''s.
2817 Plain ''italic'''s plain
2819 <p><i><b>Bold italic text </b>with bold deactivated<b> in between.</b></i>
2820 </p><p><b><i>Bold italic text </i>with italic deactivated<i> in between.</i></b>
2821 </p><p><b>Bold text..</b>
2822 </p><p>..spanning two paragraphs (should not work).
2823 </p><p><b>Bold tag left open</b>
2824 </p><p><i>Italic tag left open</i>
2826 </p><p><b>This year'</b>s election <i>should</i> beat <b>last year'</b>s.
2827 </p><p><i>Tom<b>s car is bigger than </b></i><b>Susan</b>s.
2828 </p><p>Plain <i>italic'</i>s plain
2835 ### some content taken from http://meta.wikimedia.org/wiki/MediaWiki_User%27s_Guide:_Using_tables
2838 # This should not produce <table></table> as <table><tr><td></td></tr></table>
2839 # is the bare minimun required by the spec, see:
2840 # http://www.w3.org/TR/xhtml-modularization/dtd_module_defs.html#a_module_Basic_Tables
2842 A table with no data.
2848 # A table with nothing but a caption is invalid XHTML, we might want to render
2849 # this as <p>caption</p>
2851 A table with nothing but a caption
2859 </caption><tr><td></td></tr></table>
2864 A table with caption with default-spaced attributes and a table row
2867 |+ style="color: red;" | caption1
2873 <caption style="color: red;"> caption1
2882 A table with captions with non-default spaced attributes and a table row
2885 |+style="color: red;"|caption2
2886 |+ style="color: red;"| caption3
2892 <caption style="color: red;">caption2
2894 <caption style="color: red;"> caption3
2903 Table td-cell syntax variations
2907 | foo bar foo || baz
2908 | style='color:red;' | baz
2909 | style='color:red;' || baz
2916 <td> foo bar foo </td>
2919 <td style="color:red;"> baz
2921 <td> style='color:red;' </td>
2949 Simple table but with multiple dashes for row wikitext
2967 Multiplication table
2969 {| border="1" cellpadding="2"
2970 |+Multiplication table
2972 ! × !! 1 !! 2 !! 3
2990 <table border="1" cellpadding="2">
2991 <caption>Multiplication table
3038 Accept "||" in table headings
3053 Accept "||" in indented table headings
3063 </th></tr></table></dd></dl>
3068 Accept empty attributes in td/th cells (td/th cells starting with leading ||)
3085 Accept "| !" at start of line in tables (ignore !-attribute)
3089 | !style="color:red" | bar
3101 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 +/-
3105 |style='color:red;'|+1
3106 |style='color:blue;'|-1
3118 <td style="color:red;">+1
3120 <td style="color:blue;">-1
3144 |rowspan=2| Cell 2, row 1 (and 2)
3155 <td rowspan="2"> Cell 2, row 1 (and 2)
3173 {| bgcolor=#ABCDEF border=2
3178 |the original table again
3186 <table bgcolor="#ABCDEF" border="2">
3194 <td>the original table again
3200 Invalid attributes in table cell (bug 1830)
3215 Table security: embedded pipes (http://lists.wikimedia.org/mailman/htdig/wikitech-l/2006-April/022293.html)
3218 | |[ftp://|x||]" onmouseover="alert(document.cookie)">test
3222 <td>[<a rel="nofollow" class="external free" href="ftp://%7Cx">ftp://%7Cx</a></td>
3223 <td>]" onmouseover="alert(document.cookie)">test
3232 Indented table markup mixed with indented pre content (proposed in bug 6200)
3237 Text that should be rendered preformatted
3245 <pre>Text that should be rendered preformatted
3254 Template-generated table cell attributes and cell content
3262 <td style="color: red"> Foo
3268 Table with row followed by newlines and table heading
3286 Table with empty line following the start tag
3303 # FIXME: Preserve the attribute properly (with an empty string as value) in
3304 # the PHP parser. Parsoid implements the behavior below.
3306 Table attributes with empty value
3322 Wikitext table with a lot of comments
3345 Wikitext table with double-line table cell
3361 # The expected HTML structure in this test is debatable. The PHP parser does
3362 # not parse this kind of table at all. The main focus for Parsoid is on
3363 # round-tripping, so this output is ok for now. TODO: revisit!
3365 Wikitext table with html-syntax row (Parsoid)
3378 <td>foo</td></tr></tbody></table>
3385 Plain link, capitalized
3389 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
3394 Plain link, uncapitalized
3398 <p><a href="/wiki/Main_Page" title="Main Page">main Page</a>
3405 [[Main Page|The Main Page]]
3407 <p><a href="/wiki/Main_Page" title="Main Page">The Main Page</a>
3416 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig</a>
3421 Broken link with fragment
3423 [[Zigzagzogzagzig#zug]]
3425 <p><a href="/index.php?title=Zigzagzogzagzig&action=edit&redlink=1" class="new" title="Zigzagzogzagzig (page does not exist)">Zigzagzogzagzig#zug</a>
3430 Special page link with fragment
3432 [[Special:Version#anchor]]
3434 <p><a href="/wiki/Special:Version#anchor" title="Special:Version">Special:Version#anchor</a>
3439 Nonexistent special page link with fragment
3441 [[Special:ThisNameWillHopefullyNeverBeUsed#anchor]]
3443 <p><a href="/wiki/Special:ThisNameWillHopefullyNeverBeUsed" class="new" title="Special:ThisNameWillHopefullyNeverBeUsed (page does not exist)">Special:ThisNameWillHopefullyNeverBeUsed#anchor</a>
3450 xxx[[main Page]], xxx[[Main Page]], Xxx[[main Page]] XXX[[main Page]], XXX[[Main Page]]
3452 <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>
3459 [[Main Page]]xxx, [[Main Page]]XXX, [[Main Page]]!!!
3461 <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>!!!
3472 Bug 43661: Piped links with identical prefixes
3474 [[prefixed article|prefixed articles with spaces]]
3476 [[prefixed article|prefixed articlesaoeu]]
3478 [[Main Page|Main Page test]]
3480 <p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articles with spaces</a>
3481 </p><p><a href="/wiki/Prefixed_article" title="Prefixed article">prefixed articlesaoeu</a>
3482 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page test</a>
3488 Link with HTML entity in suffix / tail
3490 [[Main Page]]", [[Main Page]]a
3492 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>", <a href="/wiki/Main_Page" title="Main Page">Main Page</a>a
3497 Link with 3 brackets
3506 Piped link with 3 brackets
3508 [[[main page|the main page]]]
3510 <p>[[[main page|the main page]]]
3515 Link with multiple pipes
3517 [[Main Page|The|Main|Page]]
3519 <p><a href="/wiki/Main_Page" title="Main Page">The|Main|Page</a>
3526 [[Talk:Parser testing]], [[Meta:Disclaimers]]
3528 <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>
3533 Piped link to namespace
3535 [[Meta:Disclaimers|The disclaimers]]
3537 <p><a href="/index.php?title=Meta:Disclaimers&action=edit&redlink=1" class="new" title="Meta:Disclaimers (page does not exist)">The disclaimers</a>
3544 [[Usually caused by a typo (oops}]]
3546 <p>[[Usually caused by a typo (oops}]]
3551 Link containing % (not as a hex sequence)
3555 <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>
3560 Link containing % as a single hex sequence interpreted to char
3564 <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>
3569 Link containing % as a double hex sequence interpreted to hex sequence
3573 <p>[[7%2525 Solution]]
3578 Link containing "#<" and "#>" % as a hex sequences- these are valid section anchors
3579 Example for such a section: == < ==
3581 [[%23%3c]][[%23%3e]]
3583 <p><a href="#.3C">#<</a><a href="#.3E">#></a>
3588 Link containing "<#" and ">#" as a hex sequences
3590 [[%3c%23]][[%3e%23]]
3592 <p>[[%3c%23]][[%3e%23]]
3597 Link containing double-single-quotes '' (bug 4598)
3599 [[Lista d''e paise d''o munno]]
3601 <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>
3606 Link containing double-single-quotes '' in text (bug 4598 sanity check)
3608 Some [[Link|pretty ''italics'' and stuff]]!
3610 <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>!
3615 Link containing double-single-quotes '' in text embedded in italics (bug 4598 sanity check)
3617 ''Some [[Link|pretty ''italics'' and stuff]]!
3619 <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>
3624 Link with double quotes in title part (literal) and alternate part (interpreted)
3626 [[File:Denys Savchenko ''Pentecoste''.jpg]]
3630 [[''Pentecoste''|Pentecoste]]
3632 [[''Pentecoste''|''Pentecoste'']]
3634 <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>
3635 </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>
3636 </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>
3637 </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>
3642 Broken image links with HTML captions (bug 39700)
3644 [[File:Nonexistent|<script></script>]]
3645 [[File:Nonexistent|100px|<script></script>]]
3646 [[File:Nonexistent|<]]
3647 [[File:Nonexistent|a<i>b</i>c]]
3649 <p><a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
3650 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><script></script></a>
3651 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent"><</a>
3652 <a href="/index.php?title=Special:Upload&wpDestFile=Nonexistent" class="new" title="File:Nonexistent">abc</a>
3659 [[http://www.example.com]]
3661 <p>[<a rel="nofollow" class="external autonumber" href="http://www.example.com">[1]</a>]
3666 Plain link to URL with link text
3668 [[http://www.example.com Link text]]
3670 <p>[<a rel="nofollow" class="external text" href="http://www.example.com">Link text</a>]
3675 Plain link to protocol-relative URL
3677 [[//www.example.com]]
3679 <p>[<a rel="nofollow" class="external autonumber" href="//www.example.com">[1]</a>]
3684 Plain link to protocol-relative URL with link text
3686 [[//www.example.com Link text]]
3688 <p>[<a rel="nofollow" class="external text" href="//www.example.com">Link text</a>]
3693 Plain link to page with question mark in title
3699 <p><a href="/wiki/A%3Fb" title="A?b">A?b</a>
3700 </p><p><a href="/wiki/A%3Fb" title="A?b">Baz</a>
3705 # I'm fairly sure the expected result here is wrong.
3706 # We want these to be URL links, not pseudo-pages with URLs for titles....
3707 # However the current output is also pretty screwy.
3710 # I'm changing it to match the current output--it arguably makes more
3711 # sense in the light of the test above. Old expected result was:
3712 #<p>Piped link to URL: <a href="/index.php?title=Http://www.example.com&action=edit" class="new">an example URL</a>
3714 # But I think this test is bordering on "garbage in, garbage out" anyway.
3719 Piped link to URL: [[http://www.example.com|an example URL]]
3721 <p>Piped link to URL: [<a rel="nofollow" class="external text" href="http://www.example.com%7Can">example URL</a>]
3726 BUG 2: [[page|http://url/]] should link to page, not http://url/
3728 [[Main Page|http://url/]]
3730 <p><a href="/wiki/Main_Page" title="Main Page">http://url/</a>
3735 BUG 337: Escaped self-links should be bold
3739 [[Bug462]] [[Bug462]]
3741 <p><strong class="selflink">Bug462</strong> <strong class="selflink">Bug462</strong>
3746 Self-link to section should not be bold
3750 [[Main Page#section]]
3752 <p><a href="/wiki/Main_Page#section" title="Main Page">Main Page#section</a>
3763 Self-link to numeric title
3769 <p><strong class="selflink">0</strong>
3774 Link to numeric-equivalent title
3780 <p><a href="/wiki/00" title="00">00</a>
3785 <nowiki> inside a link
3787 [[Main<nowiki> Page</nowiki>]] [[Main Page|the main page <nowiki>[it's not very good]</nowiki>]]
3789 <p>[[Main Page]] <a href="/wiki/Main_Page" title="Main Page">the main page [it's not very good]</a>
3794 Non-breaking spaces in title
3796 [[ Main Page ]]
3798 <p><a href="/wiki/Main_Page" title="Main Page">  Main   Page  </a>
3803 Internal link with ca linktrail, surrounded by bold apostrophes (bug 27473 primary issue)
3809 <p><b><a href="/wiki/Main_Page" title="Main Page">Main Page</a></b>
3814 Internal link with ca linktrail, surrounded by italic apostrophes (bug 27473 primary issue)
3820 <p><i><a href="/wiki/Main_Page" title="Main Page">Main Page</a></i>
3825 Internal link with en linktrail: no apostrophes (bug 27473)
3831 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (page does not exist)">Something</a>'nice
3836 Internal link with ca linktrail with apostrophes (bug 27473)
3842 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (encara no existeix)">Something'nice</a>
3847 Internal link with kaa linktrail with apostrophes (bug 27473)
3853 <p><a href="/index.php?title=Something&action=edit&redlink=1" class="new" title="Something (bet ele jaratılmag'an)">Something'nice</a>
3858 Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved
3866 [http://wp.org ''foo'']
3868 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> bar</a>
3869 </p><p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)"> <i>bar</i></a>
3870 </p><p><a rel="nofollow" class="external text" href="http://wp.org">foo</a>
3871 </p><p><a rel="nofollow" class="external text" href="http://wp.org"><i>foo</i></a>
3876 ### Interwiki links (see maintenance/interwiki.sql)
3880 Inline interwiki link
3882 [[MeatBall:SoftSecurity]]
3884 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity</a>
3889 Inline interwiki link with empty title (bug 2372)
3893 <p><a href="http://www.usemod.com/cgi-bin/mb.pl" class="extiw" title="meatball:">MeatBall:</a>
3898 Interwiki link encoding conversion (bug 1636)
3900 *[[Wikipedia:ro:Olteniţa]]
3901 *[[Wikipedia:ro:Olteniţa]]
3903 <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>
3904 </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>
3910 Interwiki link with fragment (bug 2130)
3912 [[MeatBall:SoftSecurity#foo]]
3914 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?SoftSecurity#foo" class="extiw" title="meatball:SoftSecurity">MeatBall:SoftSecurity#foo</a>
3929 Double interlanguage link
3940 Interlanguage link, with prefix links
3952 Double interlanguage link, with prefix links (bug 8897)
3965 Parsoid-specific test: Wikilinks with should RT properly
3971 <p><a href="/index.php?title=WW_II&action=edit&redlink=1" class="new" title="WW II (lonkásá ezalí tɛ̂)">WW II</a>
3989 Broken br tag sanitization
3998 Incorrecly removing closing slashes from correctly formed XHTML
4000 <br style="clear:both;" />
4002 <p><br style="clear:both;" />
4007 Failing to transform badly formed HTML into correct XHTML
4009 <br style="clear: left;">
4010 <br style="clear: right;">
4011 <br style="clear: both;">
4013 <p><br style="clear: left;" />
4014 <br style="clear: right;" />
4015 <br style="clear: both;" />
4020 Handling html with a div self-closing tag
4029 <p><div title />
4033 <p><div title=bar />
4034 <div title=bar/>
4036 <div title="bar/"></div>
4042 Handling html with a br self-closing tag
4051 <p><br title="title" />
4052 <br title="title" />
4061 Horizontal ruler (should it add that extra space?)
4075 Horizontal ruler -- 4+ dashes render hr
4084 Horizontal ruler -- eats additional dashes on the same line
4093 Horizontal ruler -- does not collaps dashes on consecutive lines
4104 Horizontal ruler -- <4 dashes render as plain text
4113 Horizontal ruler -- Supports content following dashes on same line
4122 ### Block-level elements
4145 <ol><li>Numbered list
4162 ***#Number on level 4
4164 **#Number on level 3
4165 **#Number on level 3
4169 #** Level 3, but ordered
4172 <ol><li> with numbers
4174 <ul><li> and bullets
4176 <ol><li> and numbers
4178 </li><li>bullets again
4179 <ul><li>bullet level 2
4180 <ul><li>bullet level 3
4181 <ol><li>Number on level 4
4184 </li><li>bullet level 2
4185 <ol><li>Number on level 3
4186 </li><li>Number on level 3
4189 <ol><li>number level 2
4192 <ul><li><ul><li> Level 3
4196 <ol><li><ul><li><ul><li> Level 3, but ordered
4230 Nested lists 3 (first element empty)
4243 Nested lists 4 (first element empty)
4256 Nested lists 5 (both elements empty)
4269 Nested lists 6 (both elements empty)
4282 Nested lists 7 (skip initial nesting levels)
4286 <ul><li><ul><li><ul><li> foo
4294 Nested lists 8 (multiple nesting transitions)
4302 <ul><li><ul><li> bar
4312 1. Lists with start-of-line-transparent tokens before bullets: Comments
4326 2. Lists with start-of-line-transparent tokens before bullets: Template close
4338 Unbalanced closing block tags break a list
4339 (Disabled since php parser generates broken html -- relies on Tidy to fix up)
4349 </li></ul></div><div>
4355 Unbalanced closing non-block tags don't break a list
4356 (Disabled since php parser generates broken html -- relies on Tidy to fix up)
4366 <ul><li>a<span></span>
4372 Unclosed formatting tags that straddle lists are closed and reopened
4373 (Disabled since php parser generates broken html -- relies on Tidy to fix up)
4381 </li><li> <s> b </s>
4386 List embedded in a non-block tag
4387 (Ugly Parsoid output -- worth fixing; Disabled for PHP parser since it relies on Tidy)
4395 <p><small></small></p>
4401 <p><small></small></p>
4405 List items are not parsed correctly following a <pre> block (bug 785)
4411 <ul><li> <pre>foo</pre>
4412 </li><li> <pre>bar</pre>
4419 List items from template
4430 * notSOL{{inner list}}
4449 List interrupted by empty line or heading
4459 <ul><li><ul><li> bar
4462 <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>
4463 <ul><li> Another list item
4469 Multiple list tags generated by templates
4488 Magic Word: {{CURRENTDAY}}
4497 Magic Word: {{CURRENTDAY2}}
4506 Magic Word: {{CURRENTDAYNAME}}
4515 Magic Word: {{CURRENTDOW}}
4524 Magic Word: {{CURRENTMONTH}}
4533 Magic Word: {{CURRENTMONTHABBREV}}
4535 {{CURRENTMONTHABBREV}}
4542 Magic Word: {{CURRENTMONTHNAME}}
4544 {{CURRENTMONTHNAME}}
4551 Magic Word: {{CURRENTMONTHNAMEGEN}}
4553 {{CURRENTMONTHNAMEGEN}}
4560 Magic Word: {{CURRENTTIME}}
4569 Magic Word: {{CURRENTWEEK}} (@bug 4594)
4578 Magic Word: {{CURRENTYEAR}}
4587 Magic Word: {{FULLPAGENAME}}
4589 title=[[User:Ævar Arnfjörð Bjarmason]]
4593 <p>User:Ævar Arnfjörð Bjarmason
4598 Magic Word: {{FULLPAGENAMEE}}
4600 title=[[User:Ævar Arnfjörð Bjarmason]]
4604 <p>User:%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
4609 Magic Word: {{NAMESPACE}}
4611 title=[[User:Ævar Arnfjörð Bjarmason]]
4620 Magic Word: {{NAMESPACEE}}
4622 title=[[User:Ævar Arnfjörð Bjarmason]]
4631 Magic Word: {{NAMESPACENUMBER}}
4633 title=[[User:Ævar Arnfjörð Bjarmason]]
4642 Magic Word: {{NUMBEROFFILES}}
4651 Magic Word: {{PAGENAME}}
4653 title=[[User:Ævar Arnfjörð Bjarmason]]
4657 <p>Ævar Arnfjörð Bjarmason
4662 Magic Word: {{PAGENAME}} with metacharacters
4664 title=[['foo & bar = baz']]
4668 <p><i>'foo & bar = baz'</i>
4673 Magic Word: {{PAGENAME}} with metacharacters (bug 26781)
4675 title=[[*RFC 1234 http://example.com/]]
4679 <p>*RFC 1234 http://example.com/
4684 Magic Word: {{PAGENAMEE}}
4686 title=[[User:Ævar Arnfjörð Bjarmason]]
4690 <p>%C3%86var_Arnfj%C3%B6r%C3%B0_Bjarmason
4695 Magic Word: {{PAGENAMEE}} with metacharacters (bug 26781)
4697 title=[[*RFC 1234 http://example.com/]]
4701 <p>*RFC_1234_http://example.com/
4706 Magic Word: {{REVISIONID}}
4715 Magic Word: {{SCRIPTPATH}}
4724 Magic Word: {{SERVER}}
4728 <p><a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>
4733 Magic Word: {{SERVERNAME}}
4742 Magic Word: {{SITENAME}}
4751 Namespace 1 {{ns:1}}
4760 Namespace 1 {{ns:01}}
4769 Namespace 0 {{ns:0}} (bug 4783)
4777 Namespace 0 {{ns:00}} (bug 4783)
4785 Namespace -1 {{ns:-1}}
4794 Namespace User {{ns:User}}
4803 Namespace User talk {{ns:User_talk}}
4812 Namespace User talk {{ns:uSeR tAlK}}
4821 Namespace File {{ns:File}}
4830 Namespace File {{ns:Image}}
4839 Namespace (lang=de) Benutzer {{ns:User}}
4850 Namespace (lang=de) Benutzer Diskussion {{ns:3}}
4856 <p>Benutzer Diskussion
4864 {{urlencode:hi world?!}}
4865 {{urlencode:hi world?!|WIKI}}
4866 {{urlencode:hi world?!|PATH}}
4867 {{urlencode:hi world?!|QUERY}}
4880 Magic links: internal link to RFC (bug 479)
4884 <p><a href="/index.php?title=RFC_123&action=edit&redlink=1" class="new" title="RFC 123 (page does not exist)">RFC 123</a>
4889 Magic links: RFC (bug 479)
4893 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc822">RFC 822</a>
4898 Magic links: ISBN (bug 1937)
4902 <p><a href="/wiki/Special:BookSources/0306406152" class="internal mw-magiclink-isbn">ISBN 0-306-40615-2</a>
4907 Magic links: PMID incorrectly converts space to underscore
4911 <p><a class="external mw-magiclink-pmid" rel="nofollow" href="//www.ncbi.nlm.nih.gov/pubmed/1234?dopt=Abstract">PMID 1234</a>
4920 Nonexistent template
4922 {{thistemplatedoesnotexist}}
4924 <p><a href="/index.php?title=Template:Thistemplatedoesnotexist&action=edit&redlink=1" class="new" title="Template:Thistemplatedoesnotexist (page does not exist)">Template:Thistemplatedoesnotexist</a>
4929 Template with invalid target containing tags
4931 {{a<b>b</b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
4933 <p>{{a<b>b</b>|foo|a=b|a = b}}
4938 Template with invalid target containing unclosed tag
4940 {{a<b>|{{echo|foo}}|{{echo|a}}={{echo|b}}|a = b}}
4942 <p>{{a<b>|foo|a=b|a = b}}</b>
4949 This is a test template
4957 <p>This is a test template
4962 Template with explicit namespace
4966 <p>This is a test template
4974 This is a test template with parameter {{{param}}}
4980 {{paramtest|param=foo}}
4982 <p>This is a test template with parameter foo
4987 Template:paramtestnum
4993 Template unnamed parameter
4995 {{paramtestnum|Main Page|the main page}}
4997 <p><a href="/wiki/Main_Page" title="Main Page">the main page</a>
5002 Template:templatesimple
5008 Template:templateredirect
5010 #redirect [[Template:templatesimple]]
5014 Template:templateasargtestnum
5020 Template:templateasargtest
5022 {{template{{{templ}}}}}
5026 Template:templateasargtest2
5032 Template with template name as unnamed argument
5034 {{templateasargtestnum|templatesimple}}
5041 Template with template name as argument
5043 {{templateasargtest|templ=simple}}
5050 Template with template name as argument (2)
5052 {{templateasargtest2|templ=templatesimple}}
5059 Template:templateasargtestdefault
5061 {{{{{templ|templatesimple}}}}}
5071 Template with default value
5073 {{templateasargtestdefault}}
5080 Template with default value (value set)
5082 {{templateasargtestdefault|templ=templa}}
5091 {{templateredirect}}
5098 Template with argument in separate line
5100 {{ templateasargtest |
5108 Template with complex template as argument
5111 param ={{ templateasargtest |
5114 <p>This is a test template with parameter (test)
5119 Template with thumb image (with link in description)
5122 param =[[Image:noimage.png|thumb|[[no link|link]] [[no link|caption]]]]}}
5124 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>
5129 Template:complextemplate
5131 {{{1}}} {{paramtest|
5132 param ={{{param}}}}}
5136 Template with complex arguments
5139 param ={{ templateasargtest |
5140 templ = simple }}|[[Template:complextemplate|link]]}}
5142 <p><a href="/wiki/Template:Complextemplate" title="Template:Complextemplate">link</a> This is a test template with parameter (test)
5147 BUG 553: link with two variables in a piped link
5150 |[[{{{1}}}|{{{2}}}]]
5155 <td>[[{{{1}}}|{{{2}}}]]
5161 Magic variable as template parameter
5163 {{paramtest|param={{SITENAME}}}}
5165 <p>This is a test template with parameter MediaWiki
5172 [[{{{param}}}|link]]
5176 Template parameter as link source
5178 {{linktest|param=Main Page}}
5180 <p><a href="/wiki/Main_Page" title="Main Page">link</a>
5185 Template-generated attribute string (k='v')
5187 <span {{attr_str|id|v1}}>bar</span>
5189 <p><span id="v1">bar</span>
5196 including another template, {{paramtest|param={{{arg}}}}}
5200 Template passing argument to another template
5202 {{paramtest2|arg='hmm'}}
5204 <p>including another template, This is a test template with parameter 'hmm'
5215 Template as link source
5219 [[{{linktest2}}|Main Page]]
5221 [[{{linktest2}}]]Page
5223 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
5224 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
5225 </p><p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>Page
5243 Template infinite loop
5247 <p><span class="error">Template loop detected: <a href="/wiki/Template:Loop1" title="Template:Loop1">Template:Loop1</a></span>
5252 Template from main namespace
5271 BUG 529: Template with table, not included at beginning of line
5290 BUG 523: Template shouldn't eat newline (or add an extra one before table)
5310 BUG 41: Template parameters shown as broken links
5319 Template with targets containing wikilinks
5323 {{[[{{echo|foo}}]]}}
5325 {{{{echo|[[foo}}]]}}
5327 <p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
5328 </p><p>{{<a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">foo</a>}}
5336 ''None'' of '''this''' should be
5338 but rather passed unmodified
5342 # hmm, fix this or just deprecate msgnw and document its behavior?
5348 {{msgnw:MSGNW test}}
5350 <p>''None'' of '''this''' should be
5352 but rather passed unmodified
5360 {{int:youhavenewmessages|lots of money|not!}}
5362 <p>You have lots of money (not!).
5369 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
5373 <includeonly> and <noinclude> being included
5384 <onlyinclude>Foo</onlyinclude>bar
5388 <onlyinclude> being included
5400 <onlyinclude>Foo</onlyinclude>bar<includeonly>zar</includeonly>
5404 <onlyinclude> and <includeonly> being included
5413 <includeonly> and <noinclude> on a page
5415 Foo<noinclude>zar</noinclude><includeonly>bar</includeonly>
5422 Un-closed <noinclude>
5429 <onlyinclude> on a page
5431 <onlyinclude>Foo</onlyinclude>bar
5438 Un-closed <onlyinclude>
5445 Self-closed noinclude, includeonly, onlyinclude tags
5456 Unbalanced includeonly and noinclude tags
5460 |b</noinclude></noinclude>
5461 |c</noinclude></includeonly>
5462 |d</includeonly></includeonly>
5471 <td>c</includeonly>
5473 <td>d</includeonly></includeonly>
5479 Template:Includeonly section
5482 ==Includeonly section==
5488 Bug 6563: Edit link generation for section shown by <includeonly>
5490 {{includeonly section}}
5492 <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>
5493 <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>
5497 # Uses same input as the contents of [[Template:Includeonly section]]
5499 Bug 6563: Section extraction for section shown by <includeonly>
5504 ==Includeonly section==
5512 Bug 6563: Edit link generation for section suppressed by <includeonly>
5515 ==Includeonly section==
5519 <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>
5524 Bug 6563: Section extraction for section suppressed by <includeonly>
5529 ==Includeonly section==
5537 Un-closed <includeonly>
5544 ### <includeonly> and <noinclude> in attributes
5547 0. includeonly around the entire attribute
5549 <span <includeonly>id="v1"</includeonly><noinclude>id="v2"</noinclude>>bar</span>
5551 <p><span id="v2">bar</span>
5556 1. includeonly in html attr key
5558 <span <noinclude>id</noinclude><includeonly>about</includeonly>="foo">bar</span>
5560 <p><span id="foo">bar</span>
5565 2. includeonly in html attr value
5567 <span id="<noinclude>v1</noinclude><includeonly>v2</includeonly>">bar</span>
5568 <span id=<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>>bar</span>
5570 <p><span id="v1">bar</span>
5571 <span id="v1">bar</span>
5576 3. includeonly in part of an attr value
5578 <span style="color:<noinclude>red</noinclude><includeonly>blue</includeonly>;">bar</span>
5580 <p><span style="color:red;">bar</span>
5585 ### Testing parsing of templates where a template arg
5586 ### has the same name as the template itself.
5596 Templates: Template Name/Arg clash: 1. Use of positional param
5605 Templates: Template Name/Arg clash: 2. Use of named param
5614 Templates: Template Name/Arg clash: 3. Use of named param with empty input
5623 ### Parsoid-centric tests to stress Parsoid's ability to RT them unchanged
5627 Templates: 1. Simple use
5636 Templates: 2. Inside a block tag
5638 <div>{{echo|Foo}}</div>
5645 Templates: P-wrapping: 1a. Templates on consecutive lines
5656 Templates: P-wrapping: 1b. Templates on consecutive lines
5670 Templates: P-wrapping: 1c. Templates on consecutive lines
5673 {{echo|bar}} <div>baz</div>
5682 Templates: Inline Text: 1. Multiple tmeplate uses
5684 {{echo|Foo}}bar{{echo|baz}}
5691 Templates: Inline Text: 2. Back-to-back template uses
5693 {{echo|Foo}}{{echo|bar}}
5700 Templates: Block Tags: 1. Multiple template uses
5702 {{echo|<div>Foo</div>}}<div>bar</div>{{echo|<div>baz</div>}}
5704 <div>Foo</div><div>bar</div><div>baz</div>
5709 Templates: Block Tags: 2. Back-to-back template uses
5711 {{echo|<div>Foo</div>}}{{echo|<div>bar</div>}}
5713 <div>Foo</div><div>bar</div>
5718 Templates: Links: 1. Simple example
5720 {{echo|[[Foo|bar]]}}
5722 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
5727 Templates: Links: 2. Generation of link href
5729 [[{{echo|Foo}}|bar]]
5731 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
5736 Templates: Links: 3. Generation of part of a link href
5738 [[Fo{{echo|o}}|bar]]
5742 [[Foo{{echo|bar}}baz]]
5744 [[Foo{{echo|bar}}|bar]]
5746 [[:Foo{{echo|bar}}]]
5748 [[:Foo{{echo|bar}}|bar]]
5750 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
5751 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
5752 </p><p><a href="/index.php?title=Foobarbaz&action=edit&redlink=1" class="new" title="Foobarbaz (page does not exist)">Foobarbaz</a>
5753 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
5754 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
5755 </p><p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">bar</a>
5760 Templates: Links: 4. Multiple templates generating link href
5762 [[{{echo|F}}{{echo|o}}ob{{echo|ar}}]]
5764 <p><a href="/index.php?title=Foobar&action=edit&redlink=1" class="new" title="Foobar (page does not exist)">Foobar</a>
5769 Templates: Links: 5. Generation of link text
5771 [[Foo|{{echo|bar}}]]
5773 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
5778 Templates: Links: 5. Nested templates (only outermost template should be marked)
5780 {{echo|[[{{echo|Foo}}|bar]]}}
5782 <p><a href="/index.php?title=Foo&action=edit&redlink=1" class="new" title="Foo (page does not exist)">bar</a>
5787 Templates: HTML Tag: 1. Generation of HTML attr. key
5789 <div {{echo|style}}="color:red;">foo</div>
5791 <div style="color:red;">foo</div>
5796 Templates: HTML Tag: 2. Generation of HTML attr. value
5798 <div style={{echo|'color:red;'}}>foo</div>
5800 <div style="color:red;">foo</div>
5805 Templates: HTML Tag: 3. Generation of HTML attr key and value
5807 <div {{echo|style}}={{echo|'color:red;'}}>foo</div>
5809 <div style="color:red;">foo</div>
5814 Templates: HTML Tag: 4. Generation of starting piece of HTML attr value
5816 <div title="{{echo|This is a long title}} with just one piece templated">foo</div>
5818 <div title="This is a long title with just one piece templated">foo</div>
5823 Templates: HTML Tag: 5. Generation of middle piece of HTML attr value
5825 <div title="This is a long title with just {{echo|one piece}} templated">foo</div>
5827 <div title="This is a long title with just one piece templated">foo</div>
5832 Templates: HTML Tag: 6. Generation of end piece of HTML attr value
5834 <div title="This is a long title with just one piece {{echo|templated}}">foo</div>
5836 <div title="This is a long title with just one piece templated">foo</div>
5841 Templates: HTML Tables: 1. Generating start of a HTML table
5843 {{echo|<table><tr><td>foo</td>}}</tr></table>
5845 <table><tr><td>foo</td></tr></table>
5850 Templates: HTML Tables: 2a. Generating middle of a HTML table
5852 <table><tr>{{echo|<td>foo</td>}}</tr></table>
5854 <table><tr><td>foo</td></tr></table>
5859 Templates: HTML Tables: 2b. Generating middle of a HTML table
5861 <table>{{echo|<tr><td>foo</td></tr>}}</table>
5863 <table><tr><td>foo</td></tr></table>
5868 Templates: HTML Tables: 3. Generating end of a HTML table
5870 <table><tr>{{echo|<td>foo</td></tr></table>}}
5872 <table><tr><td>foo</td></tr></table>
5877 Templates: HTML Tables: 4a. Generating a single tag of a HTML table
5879 {{echo|<table>}}<tr><td>foo</td></tr></table>
5881 <table><tr><td>foo</td></tr></table>
5886 Templates: HTML Tables: 4b. Generating a single tag of a HTML table
5888 <table>{{echo|<tr>}}<td>foo</td></tr></table>
5890 <table><tr><td>foo</td></tr></table>
5895 Templates: HTML Tables: 4c. Generating a single tag of a HTML table
5897 <table><tr>{{echo|<td>}}foo</td></tr></table>
5899 <table><tr><td>foo</td></tr></table>
5904 Templates: HTML Tables: 4d. Generating a single tag of a HTML table
5906 <table><tr><td>foo{{echo|</td>}}</tr></table>
5908 <table><tr><td>foo</td></tr></table>
5913 Templates: HTML Tables: 4e. Generating a single tag of a HTML table
5915 <table><tr><td>foo</td>{{echo|</tr>}}</table>
5917 <table><tr><td>foo</td></tr></table>
5922 Templates: HTML Tables: 4f. Generating a single tag of a HTML table
5924 <table><tr><td>foo</td></tr>{{echo|</table>}}
5926 <table><tr><td>foo</td></tr></table>
5931 Templates: Wiki Tables: 1a. Fostering of entire template content
5939 <tr><td></td></tr></table>
5944 Templates: Wiki Tables: 1b. Fostering of entire template content
5957 <tr><td></td></tr></table>
5962 Templates: Wiki Tables: 2. Fostering of partial template content
5972 <tr><td></td></tr></table>
5977 Templates: Wiki Tables: 3. td-content via multiple templates
5980 {{echo|{{pipe}}a}}{{echo|b}}
5991 Templates: Wiki Tables: 4. Templated tags, no content
5997 <tr><td></td></tr></table>
6002 Templates: Wiki Tables: 5. Templated tags, regular td-tags
6016 Templates: Wiki Tables: 6. Templated tags, templated td-tags
6030 Templates: Lists: Multi-line list-items via templates
6032 *{{echo|a {{nonexistent|
6034 *{{echo|b {{nonexistent|
6037 <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>
6038 </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>
6044 Templates: Ugly nesting: 1. Quotes opened/closed across templates (echo)
6046 {{echo|''a}}{{echo|b''c''d}}{{echo|''e}}
6048 <p><i>ab</i>c<i>d</i>e
6053 Templates: Ugly nesting: 2. Quotes opened/closed across templates (echo_with_span)
6054 (PHP parser generates misnested html)
6058 {{echo_with_span|''a}}{{echo_with_span|b''c''d}}{{echo_with_span|''e}}
6060 <p><span><i>a</i></span><i><span>b</span></i><span>c</span><i>d</i><span>e</span></p>
6064 Templates: Ugly nesting: 3. Quotes opened/closed across templates (echo_with_div)
6065 (PHP parser generates misnested html)
6069 {{echo_with_div|''a}}{{echo_with_div|b''c''d}}{{echo_with_div|''e}}
6072 <div><i>b</i>c<i>d</i></div>
6077 Templates: Ugly nesting: 4. Divs opened/closed across templates
6079 a<div>b{{echo|c</div>d}}e
6086 Templates: Ugly templates: 1. Navbox template parses badly leading to table misnesting
6092 |{{echo|foo</table>}}
6096 <table about="#mwt1" typeof="mw:Object/Template ">
6097 <tbody><tr><td>foo</td></tr></tbody></table><span about="#mwt1">
6098 bar</span><span about="#mwt1">
6103 Templates: Ugly templates: 2. Navbox template parses badly leading to table misnesting
6113 <td>1. {{echo|foo </table>}}</td>
6115 <td>2. {{echo|baz </table>}}</td>
6128 <table about="#mwt1" typeof="mw:Object/Template">
6133 <td >1. foo </td></tr></tbody></table></td>
6135 <td >2. baz </td></tr></tbody></table><span about="#mwt1">
6136 </span><span about="#mwt1">
6138 abc</span><span about="#mwt1">
6139 </span><span about="#mwt1">
6140 </span><span about="#mwt1">
6141 </span><span about="#mwt1">
6142 </span><span about="#mwt1">
6144 xyz</span><span about="#mwt1">
6145 </span><span about="#mwt1">
6150 Templates: Ugly templates: 3. newline-only template parameter
6159 # This looks like a bug: a single newline triggers p/br for some reason.
6161 Templates: Ugly templates: 4. newline-only template parameter inconsistency
6172 Parser Functions: 1. Simple example
6181 Parser Functions: 2. Nested use (only outermost should be marked up)
6190 ### Pre-save transform tests
6193 pre-save transform: subst:
6199 This is a test template
6203 pre-save transform: normal template
6213 pre-save transform: nonexistent template
6217 {{thistemplatedoesnotexist}}
6219 {{thistemplatedoesnotexist}}
6224 pre-save transform: subst magic variables
6233 # This is bug 89, which I fixed. -- wtm
6235 pre-save transform: subst: templates with parameters
6239 {{subst:paramtest|param="something else"}}
6241 This is a test template with parameter "something else"
6247 <nowiki>'''not wiki'''</nowiki>
6251 pre-save transform: nowiki in subst (bug 1188)
6255 {{subst:nowikitest}}
6257 <nowiki>'''not wiki'''</nowiki>
6262 Template:commenttest
6264 This template has <!-- a comment --> in it.
6268 pre-save transform: comment in subst (bug 1936)
6272 {{subst:commenttest}}
6274 This template has <!-- a comment --> in it.
6278 pre-save transform: unclosed tag
6282 <nowiki>'''not wiki'''
6284 <nowiki>'''not wiki'''
6288 pre-save transform: mixed tag case
6292 <NOwiki>'''not wiki'''</noWIKI>
6294 <NOwiki>'''not wiki'''</noWIKI>
6298 pre-save transform: unclosed comment in <nowiki>
6302 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
6304 wiki<nowiki>nowiki<!--nowiki</nowiki>wiki
6310 <span onmouseover="alert('crap')">Oh no</span>
6314 (confirming safety of fix for subst bug 1936)
6316 {{Template:dangerous}}
6318 <p><span>Oh no</span>
6323 pre-save transform: comment containing gallery (bug 5024)
6327 <!-- <gallery>data</gallery> -->
6329 <!-- <gallery>data</gallery> -->
6333 pre-save transform: comment containing extension
6337 <!-- <tag>data</tag> -->
6339 <!-- <tag>data</tag> -->
6343 pre-save transform: comment containing nowiki
6347 <!-- <nowiki>data</nowiki> -->
6349 <!-- <nowiki>data</nowiki> -->
6353 pre-save transform: <noinclude> in subst (bug 3298)
6363 pre-save transform: <onlyinclude> in subst (bug 3298)
6375 {{<includeonly>subst:</includeonly>Includes}}
6379 Template:SafeSubstTest
6381 {{<includeonly>safesubst:</includeonly>Includes}}
6385 bug 22297: safesubst: works during PST
6389 {{subst:SafeSubstTest}}{{safesubst:SubstTest}}
6395 bug 22297: safesubst: works during normal parse
6404 subst: does not work during normal parse
6408 <p>{{subst:Includes}}
6413 pre-save transform: context links ("pipe trick")
6417 [[Article (context)|]]
6420 [[Bar:Article (context)|]]
6421 [[:Bar:Article (context)|]]
6423 [[|Article (context)]]
6427 [[Article (context)|Article]]
6428 [[Bar:Article|Article]]
6429 [[:Bar:Article|Article]]
6430 [[Bar:Article (context)|Article]]
6431 [[:Bar:Article (context)|Article]]
6433 [[Article (context)]]
6434 [[Bar:X (Y) Z|X (Y) Z]]
6435 [[:Bar:X (Y) Z|X (Y) Z]]
6439 pre-save transform: context links ("pipe trick") with interwiki prefix
6443 [[interwiki:Article|]]
6444 [[:interwiki:Article|]]
6445 [[interwiki:Bar:Article|]]
6446 [[:interwiki:Bar:Article|]]
6448 [[interwiki:Article|Article]]
6449 [[:interwiki:Article|Article]]
6450 [[interwiki:Bar:Article|Bar:Article]]
6451 [[:interwiki:Bar:Article|Bar:Article]]
6455 pre-save transform: context links ("pipe trick") with parens in title
6457 pst title=[[Somearticle (context)]]
6461 [[Article (context)|Article]]
6465 pre-save transform: context links ("pipe trick") with comma in title
6467 pst title=[[Someplace, Somewhere]]
6470 [[Otherplace, Elsewhere|]]
6471 [[Otherplace, Elsewhere, Anywhere|]]
6473 [[Otherplace, Somewhere|Otherplace]]
6474 [[Otherplace, Elsewhere|Otherplace]]
6475 [[Otherplace, Elsewhere, Anywhere|Otherplace]]
6479 pre-save transform: context links ("pipe trick") with parens and comma
6481 pst title=[[Someplace (IGNORED), Somewhere]]
6484 [[Otherplace (place), Elsewhere|]]
6486 [[Otherplace, Somewhere|Otherplace]]
6487 [[Otherplace (place), Elsewhere|Otherplace]]
6491 pre-save transform: context links ("pipe trick") with comma and parens
6493 pst title=[[Who, me? (context)]]
6496 [[Me, Myself, and I (1937 song)|]]
6498 [[Yes, you. (context)|Yes, you.]]
6499 [[Me, Myself, and I (1937 song)|Me, Myself, and I]]
6503 pre-save transform: context links ("pipe trick") with namespace
6505 pst title=[[Ns:Somearticle]]
6509 [[Ns:Article|Article]]
6513 pre-save transform: context links ("pipe trick") with namespace and parens
6515 pst title=[[Ns:Somearticle (context)]]
6519 [[Ns:Article (context)|Article]]
6523 pre-save transform: context links ("pipe trick") with namespace and comma
6525 pst title=[[Ns:Somearticle, Context, Whatever]]
6529 [[Ns:Article, Context, Whatever|Article]]
6533 pre-save transform: context links ("pipe trick") with namespace, comma and parens
6535 pst title=[[Ns:Somearticle, Context (context)]]
6539 [[Ns:Article (context)|Article]]
6543 pre-save transform: context links ("pipe trick") with namespace, parens and comma
6545 pst title=[[Ns:Somearticle (IGNORED), Context]]
6549 [[Ns:Article, Context|Article]]
6553 pre-save transform: context links ("pipe trick") with full-width parens and no space (Japanese and Chinese style, bug 30149)
6557 [[Article(context)|]]
6558 [[Bar:Article(context)|]]
6559 [[:Bar:Article(context)|]]
6560 [[|Article(context)]]
6564 [[Article(context)|Article]]
6565 [[Bar:Article(context)|Article]]
6566 [[:Bar:Article(context)|Article]]
6567 [[Article(context)]]
6569 [[:Bar:X(Y)Z|X(Y)Z]]
6573 pre-save transform: context links ("pipe trick") with full-width parens and space (Japanese and Chinese style, bug 30149)
6577 [[Article (context)|]]
6578 [[Bar:Article (context)|]]
6579 [[:Bar:Article (context)|]]
6580 [[|Article (context)]]
6584 [[Article (context)|Article]]
6585 [[Bar:Article (context)|Article]]
6586 [[:Bar:Article (context)|Article]]
6587 [[Article (context)]]
6588 [[Bar:X (Y) Z|X (Y) Z]]
6589 [[:Bar:X (Y) Z|X (Y) Z]]
6593 pre-save transform: context links ("pipe trick") with parens and no space (Korean style, bug 30149)
6597 [[Article(context)|]]
6598 [[Bar:Article(context)|]]
6599 [[:Bar:Article(context)|]]
6600 [[|Article(context)]]
6604 [[Article(context)|Article]]
6605 [[Bar:Article(context)|Article]]
6606 [[:Bar:Article(context)|Article]]
6607 [[Article(context)]]
6609 [[:Bar:X(Y)Z|X(Y)Z]]
6613 pre-save transform: context links ("pipe trick") with commas (bug 21660)
6617 [[Article (context), context|]]
6618 [[Article (context),context|]]
6619 [[Bar:Article (context), context|]]
6620 [[Bar:Article (context),context|]]
6621 [[:Bar:Article (context), context|]]
6622 [[:Bar:Article (context),context|]]
6624 [[Article (context), context|Article]]
6625 [[Article (context),context|Article]]
6626 [[Bar:Article (context), context|Article]]
6627 [[Bar:Article (context),context|Article]]
6628 [[:Bar:Article (context), context|Article]]
6629 [[:Bar:Article (context),context|Article]]
6633 pre-save transform: trim trailing empty lines
6637 Empty lines are trimmed
6643 Empty lines are trimmed
6647 pre-save transform: Signature expansion
6652 * <noinclude>~~~</noinclude>
6653 * <includeonly>~~~</includeonly>
6654 * <onlyinclude>~~~</onlyinclude>
6656 * [[Special:Contributions/127.0.0.1|127.0.0.1]]
6657 * <noinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</noinclude>
6658 * <includeonly>[[Special:Contributions/127.0.0.1|127.0.0.1]]</includeonly>
6659 * <onlyinclude>[[Special:Contributions/127.0.0.1|127.0.0.1]]</onlyinclude>
6664 pre-save transform: Signature expansion in nowiki tags (bug 93)
6670 <nowiki>~~~~</nowiki>
6672 <includeonly><nowiki>~~~~</nowiki></includeonly>
6674 <noinclude><nowiki>~~~~</nowiki></noinclude>
6676 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
6678 {{subst:Foo}} shall be converted to FOO
6680 As well as inside noinclude/onlyinclude
6681 <noinclude>{{subst:Foo}}</noinclude>
6682 <onlyinclude>{{subst:Foo}}</onlyinclude>
6684 But not inside includeonly
6685 <includeonly>{{subst:Foo}}</includeonly>
6689 <nowiki>~~~~</nowiki>
6691 <includeonly><nowiki>~~~~</nowiki></includeonly>
6693 <noinclude><nowiki>~~~~</nowiki></noinclude>
6695 <onlyinclude><nowiki>~~~~</nowiki></onlyinclude>
6697 FOO shall be converted to FOO
6699 As well as inside noinclude/onlyinclude
6700 <noinclude>FOO</noinclude>
6701 <onlyinclude>FOO</onlyinclude>
6703 But not inside includeonly
6704 <includeonly>{{subst:Foo}}</includeonly>
6708 ### Message transform tests
6711 message transform: magic variables
6721 message transform: should not transform wiki markup
6731 message transform: <noinclude> in transcluded template (bug 4926)
6741 message transform: <onlyinclude> in transcluded template (bug 4926)
6751 {{#special:}} page name, known
6755 {{#special:Recentchanges}}
6757 Special:RecentChanges
6761 {{#special:}} page name with subpage, known
6765 {{#special:Recentchanges/param}}
6767 Special:RecentChanges/param
6771 {{#special:}} page name, unknown
6775 {{#special:foobarnonexistent}}
6777 No such special page
6781 {{#speciale:}} page name, known
6785 {{#speciale:Recentchanges}}
6787 Special:RecentChanges
6791 {{#speciale:}} page name with subpage, known
6795 {{#speciale:Recentchanges/param}}
6797 Special:RecentChanges/param
6801 {{#speciale:}} page name, unknown
6805 {{#speciale:foobarnonexistent}}
6807 No_such_special_page
6816 [[Image:foobar.jpg]]
6818 <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>
6825 [[Image:foobar.jpg|right]]
6827 <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>
6832 Simple image (using File: namespace, now canonical)
6836 <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>
6843 [[Image:foobar.jpg|right|Caption text]]
6845 <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>
6850 Image with empty attribute
6852 [[Image:foobar.jpg|right||Caption text]]
6854 <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>
6859 Image with link tails
6861 123[[Image:foobar.jpg]]456
6862 123[[Image:foobar.jpg|right]]456
6863 123[[Image:foobar.jpg|thumb]]456
6865 <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
6867 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
6868 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
6873 Image with multiple captions -- only last one is accepted
6875 [[Image:foobar.jpg|right|Caption1 - ignored|[[Caption2]] - ignored|Caption3 - accepted]]
6877 <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>
6882 Image with width attribute at different positions
6884 [[Image:foobar.jpg|200px|right|Caption]]
6885 [[Image:foobar.jpg|right|200px|Caption]]
6886 [[Image:foobar.jpg|right|Caption|200px]]
6888 <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>
6889 <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>
6890 <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>
6895 Image with link parameter, wiki target
6897 [[Image:foobar.jpg|link=Target page]]
6899 <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>
6904 Image with link parameter, URL target
6906 [[Image:foobar.jpg|link=http://example.com/]]
6908 <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>
6913 Image with link parameter, wgExternalLinkTarget
6915 [[Image:foobar.jpg|link=http://example.com/]]
6917 wgExternalLinkTarget='foobar'
6919 <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>
6924 Image with link parameter, wgNoFollowLinks set to false
6926 [[Image:foobar.jpg|link=http://example.com/]]
6928 wgNoFollowLinks=false
6930 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
6935 Image with link parameter, wgNoFollowDomainExceptions
6937 [[Image:foobar.jpg|link=http://example.com/]]
6939 wgNoFollowDomainExceptions='example.com'
6941 <p><a href="http://example.com/"><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" /></a>
6946 Image with link parameter, wgExternalLinkTarget, unnamed parameter
6948 [[Image:foobar.jpg|link=http://example.com/|Title]]
6950 wgExternalLinkTarget='foobar'
6952 <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>
6957 Image with empty link parameter
6959 [[Image:foobar.jpg|link=]]
6961 <p><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220" />
6966 Image with link parameter (wiki target) and unnamed parameter
6968 [[Image:foobar.jpg|link=Target page|Title]]
6970 <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>
6975 Image with link parameter (URL target) and unnamed parameter
6977 [[Image:foobar.jpg|link=http://example.com/|Title]]
6979 <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>
6984 Thumbnail image with link parameter
6986 [[Image:foobar.jpg|thumb|link=http://example.com/|Title]]
6988 <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>
6993 Image with frame and link
6995 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]]]
6997 <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>
7002 Image with frame and link and explicit alt
7004 [[Image:Foobar.jpg|frame|left|This is a test image [[Main Page]]|alt=Altitude]]
7006 <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>
7011 Image with wiki markup in implicit alt
7013 [[Image:Foobar.jpg|testing '''bold''' in alt]]
7015 <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>
7020 Image with wiki markup in explicit alt
7022 [[Image:Foobar.jpg|alt=testing '''bold''' in alt]]
7024 <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>
7029 Link to image page- image page normally doesn't exists, hence edit link
7030 Add test with existing image page
7031 #<p><a href="/wiki/File:Test" title="Image:Test">Image:test</a>
7035 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">Image:test</a>
7040 bug 18784 Link to non-existent image page with caption should use caption as link text
7042 [[:Image:test|caption]]
7044 <p><a href="/index.php?title=File:Test&action=edit&redlink=1" class="new" title="File:Test (page does not exist)">caption</a>
7049 Frameless image caption with a free URL
7051 [[Image:foobar.jpg|http://example.com]]
7053 <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>
7058 Thumbnail image caption with a free URL
7060 [[Image:foobar.jpg|thumb|http://example.com]]
7062 <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>
7067 Thumbnail image caption with a free URL and explicit alt
7069 [[Image:foobar.jpg|thumb|http://example.com|alt=Alteration]]
7071 <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>
7076 BUG 1887: A ISBN with a thumbnail
7078 [[Image:foobar.jpg|thumb|ISBN 1235467890]]
7080 <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>
7085 BUG 1887: A RFC with a thumbnail
7087 [[Image:foobar.jpg|thumb|This is RFC 12354]]
7089 <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>
7094 BUG 1887: A mailto link with a thumbnail
7096 [[Image:foobar.jpg|thumb|Please mailto:nobody@example.com]]
7098 <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>
7102 # Pending resolution to bug 368
7104 BUG 648: Frameless image caption with a link
7106 [[Image:foobar.jpg|text with a [[link]] in it]]
7108 <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>
7113 BUG 648: Frameless image caption with a link (suffix)
7115 [[Image:foobar.jpg|text with a [[link]]foo in it]]
7117 <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>
7122 BUG 648: Frameless image caption with an interwiki link
7124 [[Image:foobar.jpg|text with a [[MeatBall:Link]] in it]]
7126 <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>
7131 BUG 648: Frameless image caption with a piped interwiki link
7133 [[Image:foobar.jpg|text with a [[MeatBall:Link|link]] in it]]
7135 <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>
7140 Escape HTML special chars in image alt text
7142 [[Image:foobar.jpg|& < > "]]
7144 <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>
7149 BUG 499: Alt text should have Ӓ, not &1234;
7151 [[Image:foobar.jpg|♀]]
7153 <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>
7158 Broken image caption with link
7160 [[Image:Foobar.jpg|thumb|This is a broken caption. But [[Main Page|this]] is just an ordinary link.
7162 <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.
7167 Image caption containing another image
7169 [[Image:Foobar.jpg|thumb|This is a caption with another [[Image:icon.png|image]] inside it!]]
7171 <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>
7176 Image caption containing a newline
7178 [[Image:Foobar.jpg|This
7181 <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>
7186 Parsoid: Image caption containing leading space
7187 (The leading space should not trigger nowiki escaping in wt2wt mode)
7189 [[Image:Foobar.jpg|thumb| bar]]
7191 <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>
7196 Bug 3090: External links other than http: in image captions
7198 [[Image:Foobar.jpg|thumb|200px|This caption has [irc://example.net irc] and [https://example.com Secure] ext links in it.]]
7200 <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>
7207 [[Image:foobar.jpg|a|class=b]]
7209 <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>
7214 Localized image handling (1).
7218 [[Archivo:Foobar.jpg|izquierda|enlace=foo|caption]]
7220 <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>
7225 Localized image handling (2).
7229 [[Archivo:Foobar.jpg|miniatura|izquierda|enlace=foo|caption]]
7231 <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>
7236 "border", "frameless" and "class" attributes on an image.
7238 [[File:Foobar.jpg|frameless|border|class=extra|caption]]
7240 <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>
7247 #REDIRECT [[File:Barfoo.jpg]]
7253 [[Image:Barfoo.jpg]]
7255 <p><a href="/wiki/File:Barfoo.jpg" title="File:Barfoo.jpg">File:Barfoo.jpg</a>
7260 Missing image with uploads disabled
7264 [[Image:Foobaz.jpg]]
7266 <p><a href="/wiki/File:Foobaz.jpg" title="File:Foobaz.jpg">File:Foobaz.jpg</a>
7275 Subpage test/subpage
7283 subpage title=[[Subpage test]]
7287 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a>
7292 Subpage noslash link
7294 subpage title=[[Subpage test]]
7298 <p><a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">subpage</a>
7307 <p><a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a>
7312 BUG 561: {{/Subpage}}
7314 subpage title=[[Page]]
7318 <p><a href="/index.php?title=Page/Subpage&action=edit&redlink=1" class="new" title="Page/Subpage (page does not exist)">Page/Subpage</a>
7326 Category:MediaWiki User's Guide
7334 [[:Category:MediaWiki User's Guide]]
7336 <p><a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">Category:MediaWiki User's Guide</a>
7345 [[Category:MediaWiki User's Guide]]
7347 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
7351 PAGESINCATEGORY invalid title fatal (r33546 fix)
7353 {{PAGESINCATEGORY:<bogus>}}
7360 Category with different sort key
7364 [[Category:MediaWiki User's Guide|Foo]]
7366 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
7370 Category with identical sort key
7374 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
7376 <a href="/wiki/Category:MediaWiki_User%27s_Guide" title="Category:MediaWiki User's Guide">MediaWiki User's Guide</a>
7380 Category with empty sort key
7385 [[Category:MediaWiki User's Guide|]]
7387 [[Category:MediaWiki User's Guide|MediaWiki User's Guide]]
7391 Category with empty sort key and parentheses
7396 [[Category:Foo (bar)|]]
7398 [[Category:Foo (bar)|Foo]]
7402 Category with link tail
7407 123[[Category:Foo]]456
7409 123[[Category:Foo]]456
7413 Category with template
7418 [[Category:{{echo|Foo}}]]
7420 [[Category:{{echo|Foo}}]]
7424 Category with template in sort key
7429 [[Category:Foo|{{echo|Bar}}]]
7431 [[Category:Foo|{{echo|Bar}}]]
7435 Category with template in sort key and title
7440 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
7442 [[Category:{{echo|Foo}}|{{echo|Bar}}]]
7446 Category / paragraph interactions
7448 Foo [[Category:Baz]] Bar
7450 Foo [[Category:Baz]]
7458 [[Category:Baz]] Bar
7471 {{echo|[[Category:Baz]]}}
7486 ### Inter-language links
7489 Inter-language links
7495 [[zh:食品]]
7497 es:Alimento fr:Nourriture zh:食品
7501 Duplicate interlanguage links (bug 24502)
7517 Basic section headings
7524 ===Smaller headline===
7527 <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>
7530 <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>
7533 <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>
7539 Section headings with TOC
7542 === Subheadline 1 ===
7543 ===== Skipping a level =====
7544 ====== Skipping a level ======
7548 ===Another headline===
7550 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
7552 <li class="toclevel-1 tocsection-1"><a href="#Headline_1"><span class="tocnumber">1</span> <span class="toctext">Headline 1</span></a>
7554 <li class="toclevel-2 tocsection-2"><a href="#Subheadline_1"><span class="tocnumber">1.1</span> <span class="toctext">Subheadline 1</span></a>
7556 <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>
7558 <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>
7565 <li class="toclevel-1 tocsection-5"><a href="#Headline_2"><span class="tocnumber">2</span> <span class="toctext">Headline 2</span></a>
7567 <li class="toclevel-2 tocsection-6"><a href="#Another_headline"><span class="tocnumber">2.1</span> <span class="toctext">Another headline</span></a></li>
7572 <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>
7573 <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>
7574 <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>
7575 <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>
7576 <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>
7579 <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>
7583 # perl -e 'print "="x$_," Level $_ heading","="x$_,"\n" for 1..10'
7585 Handling of sections up to level 6 and beyond
7588 == Level 2 Heading==
7589 === Level 3 Heading===
7590 ==== Level 4 Heading====
7591 ===== Level 5 Heading=====
7592 ====== Level 6 Heading======
7593 ======= Level 7 Heading=======
7594 ======== Level 8 Heading========
7595 ========= Level 9 Heading=========
7596 ========== Level 10 Heading==========
7598 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
7600 <li class="toclevel-1 tocsection-1"><a href="#Level_1_Heading"><span class="tocnumber">1</span> <span class="toctext">Level 1 Heading</span></a>
7602 <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>
7604 <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>
7606 <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>
7608 <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>
7610 <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>
7611 <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>
7612 <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>
7613 <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>
7614 <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>
7627 <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>
7628 <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>
7629 <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>
7630 <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>
7631 <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>
7632 <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>
7633 <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>
7634 <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>
7635 <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>
7636 <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>
7641 TOC regression (bug 9764)
7645 ==== title 1.1.1 ====
7650 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
7652 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
7654 <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>
7656 <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>
7659 <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>
7662 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
7664 <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>
7669 <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>
7670 <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>
7671 <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>
7672 <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>
7673 <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>
7674 <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>
7679 TOC with wgMaxTocLevel=3 (bug 6204)
7685 ==== title 1.1.1 ====
7690 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
7692 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
7694 <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>
7695 <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>
7698 <li class="toclevel-1 tocsection-5"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
7700 <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>
7705 <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>
7706 <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>
7707 <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>
7708 <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>
7709 <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>
7710 <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>
7715 TOC with wgMaxTocLevel=3 and two level four headings (bug 6204)
7721 ====Section 1.1.1====
7722 ====Section 1.1.1.1====
7725 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
7727 <li class="toclevel-1 tocsection-1"><a href="#Section_1"><span class="tocnumber">1</span> <span class="toctext">Section 1</span></a>
7729 <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>
7732 <li class="toclevel-1 tocsection-5"><a href="#Section_2"><span class="tocnumber">2</span> <span class="toctext">Section 2</span></a></li>
7735 <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>
7736 <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>
7737 <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>
7738 <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>
7739 <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>
7745 Resolving duplicate section names
7750 <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>
7751 <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>
7756 Resolving duplicate section names with differing case (bug 10721)
7761 <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>
7762 <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>
7774 Template with sections, __NOTOC__
7781 <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>
7782 <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>
7783 <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>
7784 <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>
7789 __NOEDITSECTION__ keyword
7795 <h2> <span class="mw-headline" id="Section_1">Section 1</span></h2>
7796 <h2> <span class="mw-headline" id="Section_2">Section 2</span></h2>
7801 Link inside a section heading
7803 ==Section with a [[Main Page|link]] in it==
7805 <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>
7810 TOC regression (bug 12077)
7817 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
7819 <li class="toclevel-1 tocsection-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
7821 <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>
7824 <li class="toclevel-1 tocsection-3"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a></li>
7827 <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>
7828 <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>
7829 <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>
7834 BUG 1219 URL next to image (good)
7836 http://example.com [[Image:foobar.jpg]]
7838 <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>
7843 Short headings with trailing space should match behavior of Parser::doHeadings (bug 19910)
7846 The line above must have a trailing space!
7849 But just in case it doesn't...
7851 <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>
7852 <p>The line above must have a trailing space!
7854 <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>
7855 <p>But just in case it doesn't...
7860 Header with special characters (bug 25462)
7862 The tooltips shall not show entities to the user (ie. be double escaped)
7879 <p>The tooltips shall not show entities to the user (ie. be double escaped)
7881 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
7883 <li class="toclevel-1 tocsection-1"><a href="#text_.3E_text"><span class="tocnumber">1</span> <span class="toctext">text > text</span></a></li>
7884 <li class="toclevel-1 tocsection-2"><a href="#text_.3C_text"><span class="tocnumber">2</span> <span class="toctext">text < text</span></a></li>
7885 <li class="toclevel-1 tocsection-3"><a href="#text_.26_text"><span class="tocnumber">3</span> <span class="toctext">text & text</span></a></li>
7886 <li class="toclevel-1 tocsection-4"><a href="#text_.27_text"><span class="tocnumber">4</span> <span class="toctext">text ' text</span></a></li>
7887 <li class="toclevel-1 tocsection-5"><a href="#text_.22_text"><span class="tocnumber">5</span> <span class="toctext">text " text</span></a></li>
7890 <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>
7893 <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>
7896 <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>
7899 <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>
7902 <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>
7908 Headers with excess '=' characters
7909 (Are similar tests necessary beyond the 1st level?)
7913 =''italic'' heading==
7914 ==''italic'' heading=
7916 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
7918 <li class="toclevel-1 tocsection-1"><a href="#foo.3D"><span class="tocnumber">1</span> <span class="toctext">foo=</span></a></li>
7919 <li class="toclevel-1 tocsection-2"><a href="#.3Dfoo"><span class="tocnumber">2</span> <span class="toctext">=foo</span></a></li>
7920 <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>
7921 <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>
7924 <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>
7925 <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>
7926 <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>
7927 <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>
7932 HTML headers vs TOC (bug 23393)
7933 (__NOEDITSECTION__ for clearer output, doesn't matter here)
7945 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
7947 <li class="toclevel-1"><a href="#Header_1"><span class="tocnumber">1</span> <span class="toctext">Header 1</span></a>
7949 <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>
7950 <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>
7953 <li class="toclevel-1"><a href="#Header_2"><span class="tocnumber">2</span> <span class="toctext">Header 2</span></a>
7955 <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>
7956 <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>
7961 <h1> <span class="mw-headline" id="Header_1">Header 1</span></h1>
7962 <h2> <span class="mw-headline" id="Header_1.1">Header 1.1</span></h2>
7963 <h2> <span class="mw-headline" id="Header_1.2">Header 1.2</span></h2>
7964 <h1> <span class="mw-headline" id="Header_2">Header 2</span></h1>
7965 <h2> <span class="mw-headline" id="Header_2.1">Header 2.1</span></h2>
7966 <h2> <span class="mw-headline" id="Header_2.2">Header 2.2</span></h2>
7971 BUG 1219 URL next to image (broken)
7973 http://example.com[[Image:foobar.jpg]]
7975 <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>
7980 Bug 1186 news: in the middle of text
7982 http://en.wikinews.org/wiki/Wikinews:Workplace
7984 <p><a rel="nofollow" class="external free" href="http://en.wikinews.org/wiki/Wikinews:Workplace">http://en.wikinews.org/wiki/Wikinews:Workplace</a>
7990 Namespaced link must have a title
7999 Namespaced link must have a title (bad fragment version)
8001 [[Project:#fragment]]
8003 <p>[[Project:#fragment]]
8009 ### HTML tags and HTML attributes
8013 div with no attributes
8015 <div>HTML rocks</div>
8017 <div>HTML rocks</div>
8022 div with double-quoted attribute
8024 <div id="rock">HTML rocks</div>
8026 <div id="rock">HTML rocks</div>
8031 div with single-quoted attribute
8033 <div id='rock'>HTML rocks</div>
8035 <div id="rock">HTML rocks</div>
8040 div with unquoted attribute
8042 <div id=rock>HTML rocks</div>
8044 <div id="rock">HTML rocks</div>
8049 div with illegal double attributes
8051 <div id="a" id="b">HTML rocks</div>
8053 <div id="b">HTML rocks</div>
8057 # FIXME: produce empty string instead of "class" in the PHP parser, following
8060 div with empty attribute value, space before equals
8064 <div class =>HTML rocks</div>
8066 <div class="">HTML rocks</div>
8070 # The PHP parser escapes the opening brace to { for some reason, so
8071 # disabled this test for it.
8073 div with braces in attribute value
8077 <div title="{}">Foo</div>
8079 <div title="{}">Foo</div>
8082 # This it very inconsistent in the PHP parser: it returns
8083 # class="class" if there is a space between the name and the equal sign (see
8084 # 'div with empty attribute value, space before equals'), but strips the
8085 # attribute completely if the space is missing. We hope that not much content
8086 # depends on this, so are implementing the behavior below in Parsoid for
8087 # consistencies' sake. Disabled for the PHP parser.
8088 # FIXME: fix this behavior in the PHP parser?
8090 div with empty attribute value, no space before equals
8094 <div class=>HTML rocks</div>
8096 <div class="">HTML rocks</div>
8101 HTML multiple attributes correction
8103 <p class="error" class="awesome">Awesome!</p>
8105 <p class="awesome">Awesome!</p>
8110 Table multiple attributes correction
8113 !+ class="error" class="awesome"| status
8118 <th class="awesome"> status
8126 <DIV ID="x">HTML ROCKS</DIV>
8128 <div id="x">HTML ROCKS</div>
8133 Non-ASCII pseudo-tags are rendered as text
8142 Pseudo-tag with URL 'name' renders as url link
8144 <http://example.com/>
8146 <p><<a rel="nofollow" class="external free" href="http://example.com/">http://example.com/</a>>
8151 text with amp in the middle of nowhere
8155 <p>Remember AT&T?
8160 text with character entity: eacute
8162 I always thought é was a cute letter.
8164 <p>I always thought é was a cute letter.
8169 text with entity-escaped character entity-like string: eacute
8171 I always thought &eacute; was a cute letter.
8173 <p>I always thought &eacute; was a cute letter.
8178 text with undefined character entity: xacute
8180 I always thought &xacute; was a cute letter.
8182 <p>I always thought &xacute; was a cute letter.
8194 [[Media:Foobar.jpg]]
8196 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">Media:Foobar.jpg</a>
8201 Media link with text
8203 [[Media:Foobar.jpg|A neat file to look at]]
8205 <p><a href="http://example.com/images/3/3a/Foobar.jpg" class="internal" title="Foobar.jpg">A neat file to look at</a>
8209 # FIXME: this is still bad HTML tag nesting
8211 Media link with nasty text
8212 fixme: doBlockLevels won't wrap this in a paragraph because it contains a div
8214 [[Media:Foobar.jpg|Safe Link<div style=display:none>" onmouseover="alert(document.cookie)" onfoo="</div>]]
8216 <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>
8221 Media link to nonexistent file (bug 1702)
8223 [[Media:No such.jpg]]
8225 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="No such.jpg">Media:No such.jpg</a>
8230 Image link to nonexistent file (bug 1850 - good)
8232 [[Image:No such.jpg]]
8234 <p><a href="/index.php?title=Special:Upload&wpDestFile=No_such.jpg" class="new" title="File:No such.jpg">File:No such.jpg</a>
8239 :Image link to nonexistent file (bug 1850 - bad)
8241 [[:Image:No such.jpg]]
8243 <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>
8250 Character reference normalization in link text (bug 1938)
8252 [[Main Page|this&that]]
8254 <p><a href="/wiki/Main_Page" title="Main Page">this&that</a>
8261 Test for unicode normalization
8263 The page's name is U+05d0 U+05b7, with non-canonical form U+FB2E
8267 (bug 19451) Links should refer to the normalized form.
8275 <p><a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
8276 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
8277 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
8278 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
8279 <a href="/wiki/%D7%90%D6%B7" title="אַ">אַ</a>
8284 Empty attribute crash test (bug 2067)
8286 <font color="">foo</font>
8288 <p><font color="">foo</font>
8293 Empty attribute crash test single-quotes (bug 2067)
8295 <font color=''>foo</font>
8297 <p><font color="">foo</font>
8302 Attribute test: equals, then nothing
8304 <font color=>foo</font>
8311 Attribute test: unquoted value
8313 <font color=x>foo</font>
8315 <p><font color="x">foo</font>
8320 Attribute test: unquoted but illegal value (hash)
8322 <font color=#x>foo</font>
8324 <p><font color="#x">foo</font>
8329 Attribute test: no value
8331 <font color>foo</font>
8333 <p><font color="color">foo</font>
8338 Bug 2095: link with three closing brackets
8342 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>]
8347 Bug 2095: link with pipe and three closing brackets
8351 <p><a href="/wiki/Main_Page" title="Main Page">link</a>]
8356 Bug 2095: link with pipe and three closing brackets, version 2
8358 [[Main Page|[http://example.com/]]]
8360 <p><a href="/wiki/Main_Page" title="Main Page">[http://example.com/]</a>
8370 Template:Dangerous attribute
8372 " onmouseover="alert(document.cookie)
8376 Template:Dangerous style attribute
8378 border-size: expression(alert(document.cookie))
8384 <div style="float: right; {{{1}}}">Magic div</div>
8388 Bug 2304: HTML attribute safety (safe template; regression bug 2309)
8390 <div title="{{test}}"></div>
8392 <div title="This is a test template"></div>
8397 Bug 2304: HTML attribute safety (dangerous template; 2309)
8399 <div title="{{dangerous attribute}}"></div>
8401 <div title=""></div>
8406 Bug 2304: HTML attribute safety (dangerous style template; 2309)
8408 <div style="{{dangerous style attribute}}"></div>
8410 <div style="/* insecure input */"></div>
8415 Bug 2304: HTML attribute safety (safe parameter; 2309)
8417 {{div style|width: 200px}}
8419 <div style="float: right; width: 200px">Magic div</div>
8424 Bug 2304: HTML attribute safety (unsafe parameter; 2309)
8426 {{div style|width: expression(alert(document.cookie))}}
8428 <div style="/* insecure input */">Magic div</div>
8433 Bug 2304: HTML attribute safety (unsafe breakout parameter; 2309)
8435 {{div style|"><script>alert(document.cookie)</script>}}
8437 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
8442 Bug 2304: HTML attribute safety (unsafe breakout parameter 2; 2309)
8444 {{div style|" ><script>alert(document.cookie)</script>}}
8446 <div style="float: right;"><script>alert(document.cookie)</script>">Magic div</div>
8451 Bug 2304: HTML attribute safety (link)
8453 <div title="[[Main Page]]"></div>
8455 <div title="[[Main Page]]"></div>
8460 Bug 2304: HTML attribute safety (italics)
8462 <div title="''foobar''"></div>
8464 <div title="''foobar''"></div>
8469 Bug 2304: HTML attribute safety (bold)
8471 <div title="'''foobar'''"></div>
8473 <div title="'''foobar'''"></div>
8479 Bug 2304: HTML attribute safety (ISBN)
8481 <div title="ISBN 1234567890"></div>
8483 <div title="ISBN 1234567890"></div>
8488 Bug 2304: HTML attribute safety (RFC)
8490 <div title="RFC 1234"></div>
8492 <div title="RFC 1234"></div>
8497 Bug 2304: HTML attribute safety (PMID)
8499 <div title="PMID 1234567890"></div>
8501 <div title="PMID 1234567890"></div>
8506 Bug 2304: HTML attribute safety (web link)
8508 <div title="http://example.com/"></div>
8510 <div title="http://example.com/"></div>
8515 Bug 2304: HTML attribute safety (named web link)
8517 <div title="[http://example.com/ link]"></div>
8519 <div title="[http://example.com/ link]"></div>
8524 Bug 3244: HTML attribute safety (extension; safe)
8526 <div style="<nowiki>background:blue</nowiki>"></div>
8528 <div style="background:blue"></div>
8533 Bug 3244: HTML attribute safety (extension; unsafe)
8535 <div style="<nowiki>border-left:expression(alert(document.cookie))</nowiki>"></div>
8537 <div style="/* insecure input */"></div>
8541 # More MSIE fun discovered by Tom Gilder
8544 MSIE CSS safety test: spurious slash
8546 <div style="background-image:u\rl(javascript:alert('boo'))">evil</div>
8548 <div style="/* insecure input */">evil</div>
8553 MSIE CSS safety test: hex code
8555 <div style="background-image:u\72l(javascript:alert('boo'))">evil</div>
8557 <div style="/* insecure input */">evil</div>
8562 MSIE CSS safety test: comment in url
8564 <div style="background-image:u/**/rl(javascript:alert('boo'))">evil</div>
8566 <div style="background-image:u rl(javascript:alert('boo'))">evil</div>
8571 MSIE CSS safety test: comment in expression
8573 <div style="background-image:expres/**/sion(alert('boo4'))">evil4</div>
8575 <div style="background-image:expres sion(alert('boo4'))">evil4</div>
8581 Table attribute legitimate extension
8584 !+ style="<nowiki>color:blue</nowiki>"| status
8589 <th style="color:blue"> status
8595 Table attribute safety
8598 !+ style="<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>"| status
8603 <th style="/* insecure input */"> status
8609 CSS line continuation 1
8611 <div style="background-image: u\ rl(test.jpg);"></div>
8613 <div style="/* insecure input */"></div>
8618 CSS line continuation 2
8620 <div style="background-image: u\ rl(test.jpg); "></div>
8622 <div style="/* insecure input */"></div>
8633 Expansion of multi-line templates in attribute values (bug 6255)
8635 <div style="background: {{identity|#00FF00}}">-</div>
8637 <div style="background: #00FF00">-</div>
8643 Expansion of multi-line templates in attribute values (bug 6255 sanity check)
8645 <div style="background:
8648 <div style="background: #00FF00">-</div>
8653 Expansion of multi-line templates in attribute values (bug 6255 sanity check 2)
8655 <div style="background: #00FF00">-</div>
8657 <div style="background: #00FF00">-</div>
8662 ### Parser hooks (see maintenance/parserTestsParserHook.php for the <tag> extension)
8665 Parser hook: empty input
8678 Parser hook: empty input using terminated empty elements
8691 Parser hook: empty input using terminated empty elements (space before)
8704 Parser hook: basic input
8718 Parser hook: case insensitive
8732 Parser hook: case insensitive, redux
8745 Parser hook: nested tags
8749 <tag><tag></tag></tag>
8760 Parser hook: basic arguments
8762 <tag width=200 height = "100" depth = '50' square></tag>
8770 'square' => 'square',
8777 Parser hook: argument containing a forward slash (bug 5344)
8779 <tag filename='/tmp/bla'></tag>
8784 'filename' => '/tmp/bla',
8791 Parser hook: empty input using terminated empty elements (bug 2374)
8804 # </tag> should be output literally since there is no matching tag that begins it
8806 Parser hook: basic arguments using terminated empty elements (bug 2374)
8808 <tag width=200 height = "100" depth = '50' square/>
8818 'square' => 'square',
8827 ### (see maintenance/parserTestsStaticParserHook.php for the <statictag> extension)
8831 Parser hook: static parser hook not inside a comment
8833 <statictag>hello, world</statictag>
8834 <statictag action=flush/>
8842 Parser hook: static parser hook inside a comment
8844 <!-- <statictag>hello, world</statictag> -->
8845 <statictag action=flush/>
8851 # Nested template calls; this case was broken by Parser.php rev 1.506,
8855 Template:One-parameter
8857 (My parameter is: {{{1}}})
8861 Template:Map-one-parameter
8867 Nested template calls
8869 {{Map-one-parameter|One-parameter|param}}
8871 <p>(My parameter is: param)
8880 Sanitizer: Closing of open tags
8882 <s></s><table></table>
8884 <s></s><table></table>
8889 Sanitizer: Closing of open but not closed tags
8898 Sanitizer: Closing of closed but not open tags
8907 Sanitizer: Closing of closed but not open table tags
8909 Table not started</td></tr></table>
8911 <p>Table not started</td></tr></table>
8916 Sanitizer: Escaping of spaces, multibyte characters, colons & other stuff in id=""
8918 <span id="æ: v">byte</span>[[#æ: v|backlink]]
8920 <p><span id=".C3.A6:_v">byte</span><a href="#.C3.A6:_v">backlink</a>
8925 Sanitizer: Validating the contents of the id attribute (bug 4515)
8931 Something, but definitely not <br id="9" />...
8935 Sanitizer: Validating id attribute uniqueness (bug 4515, bug 6301)
8939 <br id="foo" /><br id="foo" />
8941 Something need to be done. foo-2 ?
8945 Sanitizer: Validating that <meta> and <link> work, but only for Microdata
8948 <meta itemprop="hello" content="world">
8949 <meta http-equiv="refresh" content="5">
8950 <meta itemprop="hello" http-equiv="refresh" content="5">
8951 <link itemprop="hello" href="{{SERVER}}">
8952 <link rel="stylesheet" href="{{SERVER}}">
8953 <link rel="stylesheet" itemprop="hello" href="{{SERVER}}">
8956 <div itemscope="itemscope">
8957 <p> <meta itemprop="hello" content="world" />
8958 <meta http-equiv="refresh" content="5">
8959 <meta itemprop="hello" content="5" />
8961 <link itemprop="hello" href="http://example.org" />
8962 <link rel="stylesheet" href="<a rel="nofollow" class="external free" href="http://example.org">http://example.org</a>">
8963 <link itemprop="hello" href="http://example.org" />
8969 Language converter: output gets cut off unexpectedly (bug 5757)
8973 this bit is safe: }-
8975 but if we add a conversion instance: -{zh-cn:xxx;zh-tw:yyy}-
8977 then we get cut off here: }-
8979 all additional text is vanished
8981 <p>this bit is safe: }-
8982 </p><p>but if we add a conversion instance: xxx
8983 </p><p>then we get cut off here: }-
8984 </p><p>all additional text is vanished
8989 Self closed html pairs (bug 5487)
8992 <center><font id="bug" />Centered text</center>
8993 <div><font id="bug2" />In div text</div>
8995 <center><font id="bug" />Centered text</center>
8996 <div><font id="bug2" />In div text</div>
9005 Punctuation: nbsp before exclamation
9009 <p>C'est grave !
9014 Punctuation: CSS !important (bug 11874)
9016 <div style="width:50% !important">important</div>
9018 <div style="width:50% !important">important</div>
9023 Punctuation: CSS ! important (bug 11874; with space after)
9025 <div style="width:50% ! important">important</div>
9027 <div style="width:50% ! important">important</div>
9033 HTML bullet list, closed tags (bug 5497)
9048 HTML bullet list, unclosed tags (bug 5497)
9065 HTML ordered list, closed tags (bug 5497)
9080 HTML ordered list, unclosed tags (bug 5497)
9097 HTML nested bullet list, closed tags (bug 5497)
9122 HTML nested bullet list, open tags (bug 5497)
9147 HTML nested ordered list, closed tags (bug 5497)
9172 HTML nested ordered list, open tags (bug 5497)
9197 HTML ordered list item with parameters oddity
9199 <ol><li id="fragment">One</li></ol>
9201 <ol><li id="fragment">One</li></ol>
9206 bug 5918: autonumbering
9208 [http://first/] [http://second] [ftp://ftp]
9212 [mailto:enclosed@mail.tld With target]
9214 [mailto:enclosed@mail.tld]
9216 mailto:inline@mail.tld
9218 <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>
9219 </p><p><a rel="nofollow" class="external free" href="ftp://inlineftp">ftp://inlineftp</a>
9220 </p><p><a rel="nofollow" class="external text" href="mailto:enclosed@mail.tld">With target</a>
9221 </p><p><a rel="nofollow" class="external autonumber" href="mailto:enclosed@mail.tld">[4]</a>
9222 </p><p><a rel="nofollow" class="external free" href="mailto:inline@mail.tld">mailto:inline@mail.tld</a>
9228 # Security and HTML correctness
9229 # From Nick Jenkins' fuzz testing
9233 Fuzz testing: Parser13
9248 Fuzz testing: Parser14
9253 <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>
9254 http://<table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
9256 <li class="toclevel-1 tocsection-1"><a href="#onmouseover.3D"><span class="tocnumber">1</span> <span class="toctext">onmouseover=</span></a></li>
9263 Fuzz testing: Parser14-table
9268 <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>
9269 <table style="__TOC__">
9275 # Known to produce bogus xml (extra </td>)
9277 Fuzz testing: Parser16
9297 Fuzz testing: Parser21
9300 ! irc://{{ftp://a" onmouseover="alert('hello world');"
9305 <th> <a rel="nofollow" class="external free" href="irc://{{ftp://a">irc://{{ftp://a</a>" onmouseover="alert('hello world');"
9315 Fuzz testing: Parser22
9317 http://===r:::https://b
9321 <p><a rel="nofollow" class="external free" href="http://===r:::https://b">http://===r:::https://b</a>
9329 # Known to produce bad XML for now
9331 Fuzz testing: Parser24
9338 | {{{{SSSll!!!!!!!VVVV)]]][[Special:*xxxxxxx--><noinclude>}}}} >
9339 <br style="onmouseover='alert(document.cookie);' " />
9341 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
9346 <u class="|">}}}} >
9347 <br style="onmouseover='alert(document.cookie);'" />
9349 MOVE YOUR MOUSE CURSOR OVER THIS TEXT
9358 # Note: the current result listed for this is not what the original one was,
9359 # but the original bug was JavaScript injection, which is fixed in any case.
9360 # It's not clear that the original result listed was any more correct than the
9361 # current one. Original result:
9364 # <li class="||">
9365 # }}}blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
9367 Fuzz testing: Parser25 (bug 6055)
9373 }}}blah" onmouseover="alert('hello world');" align="left"'''MOVE MOUSE CURSOR OVER HERE
9375 <p><LI CLASS=blah" onmouseover="alert('hello world');" align="left"<b>MOVE MOUSE CURSOR OVER HERE</b>
9380 Fuzz testing: URL adjacent extension (with space, clean)
9383 http://example.com <nowiki>junk</nowiki>
9385 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a> junk
9390 Fuzz testing: URL adjacent extension (no space, dirty; nowiki)
9393 http://example.com<nowiki>junk</nowiki>
9395 <p><a rel="nofollow" class="external free" href="http://example.com">http://example.com</a>junk
9400 Fuzz testing: URL adjacent extension (no space, dirty; pre)
9403 http://example.com<pre>junk</pre>
9405 <a rel="nofollow" class="external free" href="http://example.com">http://example.com</a><pre>junk</pre>
9410 Fuzz testing: image with bogus manual thumbnail
9412 [[Image:foobar.jpg|thumbnail= ]]
9414 <div class="thumb tright"><div class="thumbinner" style="width:1943px;">Error creating thumbnail: <div class="thumbcaption"></div></div></div>
9419 Fuzz testing: encoded newline in generated HTML replacements (bug 6577)
9421 <pre dir=" "></pre>
9423 <pre dir=" "></pre>
9428 Parsing optional HTML elements (Bug 6171)
9433 <td> Some tabular data</td>
9434 <td> More tabular data ...
9435 <td> And yet som tabular data</td>
9441 <td> Some tabular data</td>
9442 <td> More tabular data ...
9443 </td><td> And yet som tabular data</td>
9450 Correct handling of <td>, <tr> (Bug 6171)
9455 <td> Some tabular data</td>
9456 <td> More tabular data ...</td>
9457 <td> And yet som tabular data</td>
9463 <td> Some tabular data</td>
9464 <td> More tabular data ...</td>
9465 <td> And yet som tabular data</td>
9473 Parsing crashing regression (fr:JavaScript)
9477 <p></body></x>
9482 Inline wiki vs wiki block nesting
9488 <p><b>Bold paragraph</b>
9489 </p><p>New wiki paragraph
9494 Inline HTML vs wiki block nesting
9502 <p><b>Bold paragraph</b>
9503 </p><p>New wiki paragraph
9507 # Original result was this:
9508 # <p><b>bold</b><b>bold<i>bolditalics</i></b>
9510 # While that might be marginally more intuitive, maybe, the six-apostrophe
9511 # construct is clearly pathological and the result stated here (which is what
9512 # the parser actually does) is about as reasonable as anything.
9514 Mixing markup for italics and bold
9517 '''bold''''''bold''bolditalics'''''
9519 <p>'<i>bold'</i><b>bold<i>bolditalics</i></b>
9527 Article for special page transclusion test
9531 Special page transclusion
9534 {{Special:Prefixindex/Xyzzyx}}
9536 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
9541 Special page transclusion twice (bug 5021)
9544 {{Special:Prefixindex/Xyzzyx}}
9545 {{Special:Prefixindex/Xyzzyx}}
9547 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
9548 <table id="mw-prefixindex-list-table"><tr><td><a href="/wiki/Xyzzyx" title="Xyzzyx">Xyzzyx</a></td></tr></table>
9553 Transclusion of default MediaWiki message
9555 {{MediaWiki:Mainpage}}
9562 Transclusion of nonexistent MediaWiki message
9564 {{MediaWiki:Mainpagexxx}}
9566 <p><a href="/index.php?title=MediaWiki:Mainpagexxx&action=edit&redlink=1" class="new" title="MediaWiki:Mainpagexxx (page does not exist)">MediaWiki:Mainpagexxx</a>
9571 Transclusion of MediaWiki message with underscore
9573 {{MediaWiki:history_short}}
9580 Transclusion of MediaWiki message with space
9582 {{MediaWiki:history short}}
9589 Invalid header with following text
9599 Section extraction test (section 0)
9619 Section extraction test (section 1)
9641 Section extraction test (section 2)
9662 Section extraction test (section 3)
9682 Section extraction test (section 4)
9706 Section extraction test (section 5)
9726 Section extraction test (section 6)
9747 Section extraction test (section 7)
9767 Section extraction test (section 8)
9787 Section extraction test (section 9)
9808 Section extraction test (section 10)
9828 Section extraction test (nonexistent section 11)
9847 Section extraction test with bogus heading (section 1)
9852 ==bogus== not a legal section
9856 ==bogus== not a legal section
9860 Section extraction test with bogus heading (section 2)
9865 ==bogus== not a legal section
9872 Section extraction test with comment after heading (section 1)
9884 Section extraction test with comment after heading (section 2)
9896 Section extraction test with bogus <nowiki> heading (section 1)
9901 ==bogus== <nowiki>not a legal section</nowiki>
9905 ==bogus== <nowiki>not a legal section</nowiki>
9909 Section extraction test with bogus <nowiki> heading (section 2)
9914 ==bogus== <nowiki>not a legal section</nowiki>
9921 # Formerly testing for bug 2587, now resolved by the use of unmarked sections
9922 # instead of respecting commented sections
9924 Section extraction prefixed by comment (section 1)
9935 Section extraction prefixed by comment (section 2)
9946 # Formerly testing for bug 2607, now resolved by the use of unmarked sections
9947 # instead of respecting HTML-style headings
9949 Section extraction, mixed wiki and html (section 1)
9965 Section extraction, mixed wiki and html (section 2)
9981 # Formerly testing for bug 3342
9983 Section extraction, heading surrounded by <noinclude>
9987 <noinclude>==unmarked==</noinclude>
9993 # Test behavior of bug 19910
9995 Sectiion with all-equals
10000 The line above must have a trailing space
10003 But just in case it doesn't...
10007 But just in case it doesn't...
10011 Section replacement test (section 0)
10042 Section replacement test (section 1)
10071 Section replacement test (section 2)
10101 Section replacement test (section 3)
10132 Section replacement test (section 4)
10159 Section replacement test (section 5)
10190 Section replacement test (section 6)
10220 Section replacement test (section 7)
10251 Section replacement test (section 8)
10282 Section replacement test (section 9)
10311 Section replacement test (section 10)
10341 Section replacement test with initial whitespace (bug 13728)
10345 Preformatted initial line
10349 Preformatted initial line
10356 Section extraction, heading followed by pre with 20 spaces (bug 6398)
10368 Section extraction, heading followed by pre with 19 spaces (bug 6398 sanity check)
10381 Section extraction, <pre> around bogus header (bug 10309)
10398 Section replacement, <pre> around bogus header (bug 10309)
10400 noxml replace=2,"xxx"
10421 Handling of 
 in URLs
10425 <ul><li><ul><li><a rel="nofollow" class="external free" href="irc://%0Aa">irc://%0Aa</a>
10432 5 quotes, code coverage +1 line
10439 Special:Search page linking.
10443 <p><a href="/wiki/Special:Search" title="Special:Search">Special:Search</a>
10455 * {{BASEPAGENAMEE}}
10457 * {{TALKPAGENAMEE}}
10458 * {{SUBJECTPAGENAME}}
10459 * {{SUBJECTPAGENAMEE}}
10465 * {{SUBJECTSPACEE}}
10466 * {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}
10468 <ul><li> Parser test
10469 </li><li> Parser test
10470 </li><li> Parser test
10471 </li><li> Parser_test
10472 </li><li> Parser test
10473 </li><li> Parser_test
10474 </li><li> Talk:Parser test
10475 </li><li> Talk:Parser_test
10476 </li><li> Parser test
10477 </li><li> Parser_test
10484 </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>
10488 ### Note: Above tests excludes the "{{NUMBEROFADMINS}}" magic word because it generates a MySQL error when included.
10498 image4 |300px| centre
10499 image5.svg| http://///////
10504 <ul class="gallery">
10505 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10506 <div style="height: 150px;">Image1.png</div>
10507 <div class="gallerytext">
10510 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10511 <div style="height: 150px;">Image2.gif</div>
10512 <div class="gallerytext">
10517 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10518 <div style="height: 150px;">Image3</div>
10519 <div class="gallerytext">
10522 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10523 <div style="height: 150px;">Image4</div>
10524 <div class="gallerytext">
10529 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10530 <div style="height: 150px;">Image5.svg</div>
10531 <div class="gallerytext">
10532 <p><a rel="nofollow" class="external free" href="http://///////">http://///////</a>
10536 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10537 <div style="height: 150px;">* image6</div>
10538 <div class="gallerytext">
10546 Gallery (with options)
10548 <gallery widths='70px' heights='40px' perrow='2' caption='Foo [[Main Page]]' >
10549 File:Nonexistant.jpg|caption
10550 File:Nonexistant.jpg
10551 image:foobar.jpg|some '''caption''' [[Main Page]]
10553 image:foobar.jpg|Blabla|alt=This is a foo-bar.|blabla.
10556 <ul class="gallery" style="max-width: 226px;_width: 226px;">
10557 <li class='gallerycaption'>Foo <a href="/wiki/Main_Page" title="Main Page">Main Page</a></li>
10558 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
10559 <div style="height: 70px;">Nonexistant.jpg</div>
10560 <div class="gallerytext">
10565 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
10566 <div style="height: 70px;">Nonexistant.jpg</div>
10567 <div class="gallerytext">
10570 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
10571 <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>
10572 <div class="gallerytext">
10573 <p>some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
10577 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
10578 <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>
10579 <div class="gallerytext">
10582 <li class="gallerybox" style="width: 105px"><div style="width: 105px">
10583 <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>
10584 <div class="gallerytext">
10594 Gallery with wikitext inside caption
10597 File:foobar.jpg|[[File:foobar.jpg|20px|desc|alt=inneralt]]|alt=galleryalt
10598 File:foobar.jpg|{{Test|unamedParam|alt=param}}|alt=galleryalt
10601 <ul class="gallery">
10602 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10603 <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>
10604 <div class="gallerytext">
10605 <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>
10609 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10610 <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>
10611 <div class="gallerytext">
10612 <p>This is a test template
10621 gallery (with showfilename option)
10623 <gallery showfilename>
10624 File:Nonexistant.jpg|caption
10625 File:Nonexistant.jpg
10626 image:foobar.jpg|some '''caption''' [[Main Page]]
10630 <ul class="gallery">
10631 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10632 <div style="height: 150px;">Nonexistant.jpg</div>
10633 <div class="gallerytext">
10634 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
10639 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10640 <div style="height: 150px;">Nonexistant.jpg</div>
10641 <div class="gallerytext">
10642 <p><a href="/wiki/File:Nonexistant.jpg" title="File:Nonexistant.jpg">Nonexistant.jpg</a><br />
10646 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10647 <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>
10648 <div class="gallerytext">
10649 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
10650 some <b>caption</b> <a href="/wiki/Main_Page" title="Main Page">Main Page</a>
10654 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10655 <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>
10656 <div class="gallerytext">
10657 <p><a href="/wiki/File:Foobar.jpg" title="File:Foobar.jpg">Foobar.jpg</a><br />
10666 Gallery (with namespace-less filenames)
10669 File:Nonexistant.jpg
10675 <ul class="gallery">
10676 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10677 <div style="height: 150px;">Nonexistant.jpg</div>
10678 <div class="gallerytext">
10681 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10682 <div style="height: 150px;">Nonexistant.jpg</div>
10683 <div class="gallerytext">
10686 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10687 <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>
10688 <div class="gallerytext">
10691 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
10692 <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>
10693 <div class="gallerytext">
10701 HTML Hex character encoding (spells the word "JavaScript")
10703 JavaScript
10705 <p>JavaScript
10710 HTML Hex character encoding bogus encoding (bug 26437 regression check)
10714 <p>&#xsee;&#XSEE;
10719 HTML Hex character encoding mixed case
10728 __FORCETOC__ override
10740 ISBN 978-0-1234-56 789
10742 <p><a href="/wiki/Special:BookSources/9780123456" class="internal mw-magiclink-isbn">ISBN 978-0-1234-56</a> 789
10747 ISBN followed by 5 spaces
10758 ISBN ISBN 1234567890
10760 <p>ISBN <a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
10765 Bug 22905: <abbr> followed by ISBN followed by </a>
10767 <abbr>(fr)</abbr> ISBN 2753300917 [http://www.example.com example.com]
10769 <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>
10778 <p>RFC <a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc1234">RFC 1234</a>
10783 Double RFC with a wiki link
10787 <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>
10796 <p><a class="external mw-magiclink-rfc" rel="nofollow" href="//tools.ietf.org/html/rfc983">RFC 983</a> 987
10801 Centre-aligned image
10803 [[Image:foobar.jpg|centre]]
10805 <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>
10812 [[Image:foobar.jpg|none]]
10814 <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>
10819 Width + Height sized image (using px) (height is ignored)
10821 [[Image:foobar.jpg|640x480px]]
10823 <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>
10828 Width-sized image (using px, no following whitespace)
10830 [[Image:foobar.jpg|640px]]
10832 <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>
10837 Width-sized image (using px, with following whitespace - test regression from r39467)
10839 [[Image:foobar.jpg|640px ]]
10841 <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>
10846 Width-sized image (using px, with preceding whitespace - test regression from r39467)
10848 [[Image:foobar.jpg| 640px]]
10850 <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>
10855 Another italics / bold test
10863 # Note the results may be incorrect, as parserTest output included this:
10864 # XML error: Mismatched tag at byte 6120:
10865 # ...<dd> </dt></dl> </dd...
10873 <dl><dd><dl><dt><dl><dt><dl><dt><dl><dd><dl><dd>
10884 # Images with the "|" character in external URLs in comment tags; Eats half the comment, leaves unmatched "</a>" tag.
10886 Images with the "|" character in the comment
10888 [[image:Foobar.jpg|thumb|An [http://test/?param1=|left|¶m2=|x external] URL]]
10890 <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>
10895 [Before] HTML without raw HTML enabled ($wgRawHtml==false)
10897 <html><script>alert(1);</script></html>
10899 <p><html><script>alert(1);</script></html>
10904 HTML with raw HTML ($wgRawHtml==true)
10908 <html><script>alert(1);</script></html>
10910 <p><script>alert(1);</script>
10915 Parents of subpages, one level up
10917 subpage title=[[Subpage test/L1/L2/L3]]
10921 <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>
10927 Parents of subpages, one level up, not named
10929 subpage title=[[Subpage test/L1/L2/L3]]
10933 <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>
10940 Parents of subpages, two levels up
10942 subpage title=[[Subpage test/L1/L2/L3]]
10948 <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
10949 </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>
10954 Parents of subpages, two levels up, without trailing slash or name.
10956 subpage title=[[Subpage test/L1/L2/L3]]
10965 Parents of subpages, two levels up, with lots of extra trailing slashes.
10967 subpage title=[[Subpage test/L1/L2/L3]]
10971 <p><a href="/index.php?title=Subpage_test/L1////&action=edit&redlink=1" class="new" title="Subpage test/L1//// (page does not exist)">///</a>
10976 Definition list code coverage
10982 <dl><dt> title  </dt><dd> def
10983 </dd><dt> title </dt><dd> def
10984 </dd><dt>title</dt><dd> def
10990 Don't fall for the self-closing div
10992 <div>hello world</div/>
10994 <div>hello world</div>
11003 <p>[[:Template:Msg]]
11012 <p><a href="/index.php?title=Template:QUERTY&action=edit&redlink=1" class="new" title="Template:QUERTY (page does not exist)">Template:QUERTY</a>
11016 # This isn't needed for XHTML conformance, but would be handy as a fallback security measure
11018 Always escape literal '>' in output, not just after '<'
11032 <p>This is a test template
11033 This is a test template
11045 Inclusion of !userCanEdit() content
11049 <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>
11055 Out-of-order TOC heading levels
11064 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
11066 <li class="toclevel-1 tocsection-1"><a href="#2"><span class="tocnumber">1</span> <span class="toctext">2</span></a>
11068 <li class="toclevel-2 tocsection-2"><a href="#6"><span class="tocnumber">1.1</span> <span class="toctext">6</span></a></li>
11069 <li class="toclevel-2 tocsection-3"><a href="#3"><span class="tocnumber">1.2</span> <span class="toctext">3</span></a></li>
11072 <li class="toclevel-1 tocsection-4"><a href="#1"><span class="tocnumber">2</span> <span class="toctext">1</span></a>
11074 <li class="toclevel-2 tocsection-5"><a href="#5"><span class="tocnumber">2.1</span> <span class="toctext">5</span></a></li>
11075 <li class="toclevel-2 tocsection-6"><a href="#2_2"><span class="tocnumber">2.2</span> <span class="toctext">2</span></a></li>
11080 <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>
11081 <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>
11082 <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>
11083 <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>
11084 <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>
11085 <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>
11091 ISBN with a dummy number
11101 ISBN with space-delimited number
11105 <p><a href="/wiki/Special:BookSources/9290170328" class="internal mw-magiclink-isbn">ISBN 92 9017 032 8</a>
11111 ISBN with multiple spaces, no number
11130 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1234567890</a>
11131 </p><p>ISBN 12345678901
11137 ISBN with trailing year (bug 8110)
11139 ISBN 1-234-56789-0 - 2006
11141 ISBN 1 234 56789 0 - 2006
11143 <p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1-234-56789-0</a> - 2006
11144 </p><p><a href="/wiki/Special:BookSources/1234567890" class="internal mw-magiclink-isbn">ISBN 1 234 56789 0</a> - 2006
11152 {{anchorencode:foo bar©#%n}}
11154 <p>foo_bar.C2.A9.23.25n
11159 anchorencode trims spaces
11161 {{anchorencode: __pretty__please__}}
11168 anchorencode deals with links
11170 {{anchorencode: [[hello|world]] [[hi]]}}
11177 anchorencode deals with templates
11179 {{anchorencode: {{Foo}} }}
11186 anchorencode encodes like the TOC generator: (bug 18431)
11188 === _ +:.3A%3A&&]] ===
11189 {{anchorencode: _ +:.3A%3A&&]] }}
11192 <h3> <span class="mw-headline" id=".2B:.3A.253A.26.26.5D.5D">_ +:.3A%3A&&]]</span></h3>
11193 <p>.2B:.3A.253A.26.26.5D.5D
11197 # Expected output in the following test is not necessarily expected (there
11198 # should probably be <p> tags inside the <blockquote> in the output) -- it's
11199 # only testing for well-formedness.
11201 Bug 6200: blockquotes and paragraph formatting
11221 Bug 8293: Use of center tag ruins paragraph formatting
11243 ### Language variants related tests
11246 Self-link in language variants
11248 title=[[Dunav]] language=sr
11250 Both [[Dunav]] and [[Дунав]] are names for this river.
11252 <p>Both <strong class="selflink">Dunav</strong> and <strong class="selflink">Дунав</strong> are names for this river.
11263 Link to another existing title shouldn't be parsed as self-link even if it's a variant of this title
11265 title=[[Duna]] language=sr
11267 [[Дуна]] is not a self-link while [[Duna]] and [[Dуна]] are still self-links.
11269 <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.
11274 Link to pages in language variants
11278 Main Page can be written as [[Маин Паге]]
11280 <p>Main Page can be written as <a href="/wiki/Main_Page" title="Main Page">Маин Паге</a>
11286 Multiple links to pages in language variants
11290 [[Main Page]] can be written as [[Маин Паге]] same as [[Маин Паге]].
11292 <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>.
11298 Simple template in language variants
11304 <p>This is a test template
11310 Template with explicit namespace in language variants
11316 <p>This is a test template
11322 Basic test for template parameter in language variants
11326 {{парамтест|param=foo}}
11328 <p>This is a test template with parameter foo
11334 Simple category in language variants
11338 [[Category:МедиаWики Усер'с Гуиде]]
11340 <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>
11357 Don't convert blue categorylinks to another variant (bug 33210)
11361 [[A]][[Category:分类]]
11363 <a href="/wiki/Category:%E5%88%86%E7%B1%BB" title="Category:分类">分类</a>
11368 Stripping -{}- tags (language variants)
11372 Latin proverb: -{Ne nuntium necare}-
11374 <p>Latin proverb: Ne nuntium necare
11380 Prevent conversion with -{}- tags (language variants)
11382 language=sr variant=sr-ec
11384 Latinski: -{Ne nuntium necare}-
11386 <p>Латински: Ne nuntium necare
11392 Prevent conversion of text with -{}- tags (language variants)
11394 language=sr variant=sr-ec
11396 Latinski: -{Ne nuntium necare}-
11398 <p>Латински: Ne nuntium necare
11404 Prevent conversion of links with -{}- tags (language variants)
11406 language=sr variant=sr-ec
11410 <p><a href="/wiki/Main_Page" title="Main Page">Main Page</a>
11416 -{}- tags within headlines (within html for parserConvert())
11418 language=sr variant=sr-ec
11422 <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>
11428 Explicit definition of language variant alternatives
11430 language=zh variant=zh-tw
11432 -{zh:China;zh-tw:Taiwan}-, not China
11434 <p>Taiwan, not China
11440 Conversion around HTML tags
11442 language=sr variant=sr-ec
11444 -{H|span=>sr-ec:script;title=>sr-ec:src;}-
11445 <span title="La-{sr-el:L;sr-ec:C;}-tin">ski</span>
11448 <span title="ЛаCтин">ски</span>
11454 Explicit session-wise language variant mapping (A flag and - flag)
11456 language=zh variant=zh-tw
11458 Taiwan is not China.
11459 But -{A|zh:China;zh-tw:Taiwan}- is China,
11460 (This-{-|zh:China;zh-tw:Taiwan}- should be stripped!)
11461 and -{China}- is China.
11463 <p>Taiwan is not China.
11464 But Taiwan is Taiwan,
11465 (This should be stripped!)
11466 and China is China.
11471 Explicit session-wise language variant mapping (H flag for hide)
11473 language=zh variant=zh-tw
11475 (This-{H|zh:China;zh-tw:Taiwan}- should be stripped!)
11478 <p>(This should be stripped!)
11484 Adding explicit conversion rule for title (T flag)
11486 language=zh variant=zh-tw showtitle
11488 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
11491 <p>Should be stripped!
11496 Testing that changing the language variant here in the tests actually works
11498 language=zh variant=zh showtitle
11500 Should be stripped-{T|zh:China;zh-tw:Taiwan}-!
11503 <p>Should be stripped!
11508 Recursive conversion of alt and title attrs shouldn't clear converter state
11510 language=zh variant=zh-cn showtitle
11512 -{H|zh-cn:Exclamation;zh-tw:exclamation;}-
11513 Should be stripped-{T|zh-cn:China;zh-tw:Taiwan}-<span title="exclamation">!</span>
11517 Should be stripped<span title="Exclamation">!</span>
11522 Bug 24072: more test on conversion rule for title
11524 language=zh variant=zh-tw showtitle
11526 This should be stripped-{T|zh:China;zh-tw:Taiwan}-!
11527 This won't take interferes with the title rule-{H|zh:Beijing;zh-tw:Taipei}-.
11530 <p>This should be stripped!
11531 This won't take interferes with the title rule.
11536 Raw output of variant escape tags (R flag)
11538 language=zh variant=zh-tw
11540 Raw: -{R|zh:China;zh-tw:Taiwan}-
11542 <p>Raw: zh:China;zh-tw:Taiwan
11547 Nested using of manual convert syntax
11549 language=zh variant=zh-hk
11551 Nested: -{zh-hans:Hi -{zh-cn:China;zh-sg:Singapore;}-;zh-hant:Hello -{zh-tw:Taiwan;zh-hk:H-{ong}- K-{}-ong;}-;}-!
11553 <p>Nested: Hello Hong Kong!
11558 Proper conversion of text in external links
11560 language=sr variant=sr-ec
11562 http://www.google.com
11563 gopher://www.google.com
11564 [http://www.google.com http://www.google.com]
11565 [gopher://www.google.com gopher://www.google.com]
11566 [https://www.google.com irc://www.google.com]
11567 [ftp://www.google.com www.google.com/ftp://dir]
11568 [//www.google.com www.google.com]
11570 <p><a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
11571 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
11572 <a rel="nofollow" class="external free" href="http://www.google.com">http://www.google.com</a>
11573 <a rel="nofollow" class="external free" href="gopher://www.google.com">gopher://www.google.com</a>
11574 <a rel="nofollow" class="external text" href="https://www.google.com">irc://www.google.com</a>
11575 <a rel="nofollow" class="external text" href="ftp://www.google.com">www.гоогле.цом/фтп://дир</a>
11576 <a rel="nofollow" class="external text" href="//www.google.com">www.гоогле.цом</a>
11581 Do not convert roman numbers to language variants
11583 language=sr variant=sr-ec
11587 <p>Фридрих IV је цар.
11592 Unclosed language converter markup "-{"
11603 Don't convert raw rule "-{R|=>}-" to "=>"
11620 Bug 529: Uncovered bullet
11630 # Plain MediaWiki does not remove empty lists, but tidy actually does.
11631 # Templates in Wikipedia rely on this behavior, as tidy has always been
11632 # enabled there. These tests are normally run *without* tidy, so specify the
11633 # full output here.
11634 # To test realistic parsing behavior, apply a tidy-like transformation to both
11635 # the expected output and your parser's output.
11637 Bug 529: Uncovered bullet leaving empty list, normally removed by tidy
11639 ******* Foo {{bullet}}
11641 <ul><li><ul><li><ul><li><ul><li><ul><li><ul><li><ul><li> Foo
11654 Bug 529: Uncovered table already at line-start
11677 Bug 529: Uncovered bullet in parser function result
11679 * Foo {{lc:{{bullet}} }}
11688 Bug 5678: Double-parsed template argument
11690 {{lc:{{{1}}}|hello}}
11697 Bug 5678: Double-parsed template invocation
11699 {{lc:{{paramtest {{!}} param = hello }} }}
11701 <p>{{paramtest | param = hello }}
11706 Case insensitivity of parser functions for non-ASCII characters (bug 8143)
11709 title=[[Main Page]]
11711 {{PRVNÍVELKÉ:ěščř}}
11712 {{prvnívelké:ěščř}}
11732 Morwen/13: Unclosed link followed by heading
11739 <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>
11744 HHP2.1: Heuristics for headings in preprocessor parenthetical structures
11751 <h1> <span class="mw-headline" id="heading">heading</span></h1>
11756 HHP2.2: Heuristics for headings in preprocessor parenthetical structures
11763 <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>
11778 Paragraphs inside divs (no extra line breaks)
11790 Paragraphs inside divs (extra line break on open)
11805 Paragraphs inside divs (extra line break on close)
11820 Paragraphs inside divs (extra line break on open and close)
11837 Nesting tags, paragraphs on lines which begin with <div>
11841 <div></div><strong>A
11850 # Bug 6200: <blockquote> should behave like <div> with respect to line breaks
11852 Bug 6200: paragraphs inside blockquotes (no extra line breaks)
11856 <blockquote>Line one
11858 Line two</blockquote>
11860 <blockquote>Line one
11861 Line two</blockquote>
11866 Bug 6200: paragraphs inside blockquotes (extra line break on open)
11873 Line two</blockquote>
11878 Line two</blockquote>
11883 Bug 6200: paragraphs inside blockquotes (extra line break on close)
11887 <blockquote>Line one
11892 <blockquote>Line one
11900 Bug 6200: paragraphs inside blockquotes (extra line break on open and close)
11919 Paragraphs inside blockquotes/divs (no extra line breaks)
11921 <blockquote><div>Line one
11923 Line two</div></blockquote>
11925 <blockquote><div>Line one
11926 Line two</div></blockquote>
11931 Paragraphs inside blockquotes/divs (extra line break on open)
11936 Line two</div></blockquote>
11941 Line two</div></blockquote>
11946 Paragraphs inside blockquotes/divs (extra line break on close)
11948 <blockquote><div>Line one
11951 </div></blockquote>
11953 <blockquote><div>Line one
11956 </div></blockquote>
11961 Paragraphs inside blockquotes/divs (extra line break on open and close)
11967 </div></blockquote>
11973 </div></blockquote>
11978 Interwiki links trounced by replaceExternalLinks after early LinkHolderArray expansion
11980 wgLinkHolderBatchSize=0
11986 <p><a href="http://www.usemod.com/cgi-bin/mb.pl?1" class="extiw" title="meatball:1">meatball:1</a>
11987 <a href="http://www.usemod.com/cgi-bin/mb.pl?2" class="extiw" title="meatball:2">meatball:2</a>
11988 <a href="http://www.usemod.com/cgi-bin/mb.pl?3" class="extiw" title="meatball:3">meatball:3</a>
11993 Free external link invading image caption
11995 [[Image:Foobar.jpg|thumb|http://x|hello]]
11997 <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>
12002 Bug 15196: localised external link numbers
12006 [http://en.wikipedia.org/]
12008 <p><a rel="nofollow" class="external autonumber" href="http://en.wikipedia.org/">[۱]</a>
12013 Multibyte character in padleft
12015 {{padleft:-Hello|7|Æ}}
12022 Multibyte character in padright
12024 {{padright:Hello-|7|Æ}}
12031 formatdate parser function
12033 {{#formatdate:2009-03-24}}
12035 <p><span class="mw-formatted-date" title="2009-03-24">2009-03-24</span>
12040 formatdate parser function, with default format
12042 {{#formatdate:2009-03-24|mdy}}
12044 <p><span class="mw-formatted-date" title="2009-03-24">March 24, 2009</span>
12049 Spacing of numbers in formatted dates
12051 {{#formatdate:January 15}}
12053 <p><span class="mw-formatted-date" title="01-15">January 15</span>
12058 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
12060 language=nl title=[[MediaWiki:Common.css]]
12062 {{#formatdate:2009-03-24|dmy}}
12064 <p><span class="mw-formatted-date" title="2009-03-24">24 March 2009</span>
12077 Edit comment with link
12081 I like the [[Main Page]] a lot
12083 I like the <a href="/wiki/Main_Page" title="Main Page">Main Page</a> a lot
12087 Edit comment with link and link text
12091 I like the [[Main Page|best pages]] a lot
12093 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
12097 Edit comment with link and link text with suffix
12101 I like the [[Main Page|best page]]s a lot
12103 I like the <a href="/wiki/Main_Page" title="Main Page">best pages</a> a lot
12107 Edit comment with section link (non-local, eg in history list)
12109 comment title=[[Main Page]]
12111 /* External links */ removed bogus entries
12113 <a href="/wiki/Main_Page#External_links" title="Main Page">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
12117 Edit comment with section link and text before it (non-local, eg in history list)
12119 comment title=[[Main Page]]
12121 pre-comment text /* External links */ removed bogus entries
12123 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>
12127 Edit comment with section link (local, eg in diff view)
12129 comment local title=[[Main Page]]
12131 /* External links */ removed bogus entries
12133 <a href="#External_links">→</a><span dir="auto"><span class="autocomment">External links: </span> removed bogus entries</span>
12137 Edit comment with subpage link (bug 14080)
12141 title=[[Subpage test]]
12143 Poked at a [[/subpage]] here...
12145 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">/subpage</a> here...
12149 Edit comment with subpage link and link text (bug 14080)
12153 title=[[Subpage test]]
12155 Poked at a [[/subpage|neat little page]] here...
12157 Poked at a <a href="/wiki/Subpage_test/subpage" title="Subpage test/subpage">neat little page</a> here...
12161 Edit comment with bogus subpage link in non-subpage NS (bug 14080)
12164 title=[[Subpage test]]
12166 Poked at a [[/subpage]] here...
12168 Poked at a <a href="/index.php?title=/subpage&action=edit&redlink=1" class="new" title="/subpage (page does not exist)">/subpage</a> here...
12172 Edit comment with bare anchor link (local, as on diff)
12176 title=[[Main Page]]
12180 <a href="#section">#section</a>
12184 Edit comment with bare anchor link (non-local, as on history)
12187 title=[[Main Page]]
12191 <a href="/wiki/Main_Page#section" title="Main Page">#section</a>
12195 Anchor starting with underscore
12199 <p><a href="#_ref">One</a>
12204 Id starting with underscore
12206 <div id="_ref"></div>
12208 <div id="_ref"></div>
12213 Space normalisation on autocomment (bug 22784)
12216 title=[[Main Page]]
12218 /* __hello__world__ */
12220 <a href="/wiki/Main_Page#hello_world" title="Main Page">→</a><span dir="auto"><span class="autocomment">__hello__world__</span></span>
12224 percent-encoding and + signs in comments (Bug 26410)
12228 [[ABC%33D% ++]] [[ABC%33D% ++|+%20]]
12230 <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>
12234 Bad images - basic functionality
12243 Bad images - bug 16039: text after bad image disappears
12257 Verify that displaytitle works (bug #22501) no displaytitle
12261 wgAllowDisplayTitle=true
12262 wgRestrictDisplayTitle=false
12264 this is not the the title
12267 <p>this is not the the title
12272 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=false
12277 wgAllowDisplayTitle=true
12278 wgRestrictDisplayTitle=false
12280 this is not the the title
12281 {{DISPLAYTITLE:whatever}}
12284 <p>this is not the the title
12289 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true mismatch
12294 wgAllowDisplayTitle=true
12295 wgRestrictDisplayTitle=true
12297 this is not the the title
12298 {{DISPLAYTITLE:whatever}}
12301 <p>this is not the the title
12306 Verify that displaytitle works (bug #22501) RestrictDisplayTitle=true matching
12311 wgAllowDisplayTitle=true
12312 wgRestrictDisplayTitle=true
12314 this is not the the title
12315 {{DISPLAYTITLE:screen}}
12318 <p>this is not the the title
12323 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false
12328 wgAllowDisplayTitle=false
12330 this is not the the title
12331 {{DISPLAYTITLE:screen}}
12334 <p>this is not the the title
12335 <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>
12340 Verify that displaytitle works (bug #22501) AllowDisplayTitle=false no DISPLAYTITLE
12345 wgAllowDisplayTitle=false
12347 this is not the the title
12350 <p>this is not the the title
12355 preload: check <noinclude> and <includeonly>
12359 Hello <noinclude>cruel</noinclude><includeonly>kind</includeonly> world.
12365 preload: check <onlyinclude>
12369 Goodbye <onlyinclude>Hello world</onlyinclude>
12375 preload: can pass tags through if we want to
12379 <includeonly><</includeonly>includeonly>Hello world<includeonly><</includeonly>/includeonly>
12381 <includeonly>Hello world</includeonly>
12385 preload: check that it doesn't try to do tricks
12389 * <!-- Hello --> ''{{world}}'' {{<includeonly>subst:</includeonly>How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
12391 * <!-- Hello --> ''{{world}}'' {{subst:How are you}}{{ {{{|safesubst:}}} #if:1|2|3}}
12395 Play a bit with r67090 and bug 3158
12399 <div style="width:50% !important"> </div>
12400 <div style="width:50% !important"> </div>
12401 <div style="width:50% !important"> </div>
12402 <div style="border : solid;"> </div>
12404 <div style="width:50% !important"> </div>
12405 <div style="width:50% !important"> </div>
12406 <div style="width:50% !important"> </div>
12407 <div style="border : solid;"> </div>
12412 HTML5 data attributes
12414 <span data-foo="bar">Baz</span>
12415 <p data-abc-def_hij="">Quuz</p>
12417 <p><span data-foo="bar">Baz</span>
12419 <p data-abc-def_hij="">Quuz</p>
12424 percent-encoding and + signs in internal links (Bug 26410)
12426 [[User:+%]] [[Page+title%]]
12427 [[%+]] [[%+|%20]] [[%+ ]] [[%+r]]
12428 [[%]] [[+]] [[image:%+abc%39|foo|[[bar]]]]
12429 [[%33%45]] [[%33%45+]]
12431 <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>
12432 <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>
12433 <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>
12434 <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>
12439 Special characters in embedded file links (bug 27679)
12441 [[File:Contains & ampersand.jpg]]
12442 [[File:Does not exist.jpg|Title with & ampersand]]
12444 <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>
12445 <a href="/index.php?title=Special:Upload&wpDestFile=Does_not_exist.jpg" class="new" title="File:Does not exist.jpg">Title with & ampersand</a>
12451 Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)
12453 Text's been normalized?
12455 <p>Text's been normalized?
12460 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate free external links
12462 http://www.example.org/ <-- U+3000 (vim: ^Vu3000)
12464 <p><a rel="nofollow" class="external free" href="http://www.example.org/">http://www.example.org/</a> <-- U+3000 (vim: ^Vu3000)
12469 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links
12471 [http://www.example.org/ ideograms]
12473 <p><a rel="nofollow" class="external text" href="http://www.example.org/">ideograms</a>
12478 Bug 19052 U+3000 IDEOGRAPHIC SPACE should terminate external images links
12480 http://www.example.org/pic.png <-- U+3000 (vim: ^Vu3000)
12482 <p><img src="http://www.example.org/pic.png" alt="pic.png" /> <-- U+3000 (vim: ^Vu3000)
12506 Bug 31098 Template which includes system messages which includes the template
12510 <p><span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
12511 <span class="error">Template loop detected: <a href="/wiki/Template:Identical" title="Template:Identical">Template:Identical</a></span>
12516 Bug31490 Turkish: ucfirst 'blah'
12527 Bug31490 Turkish: ucfirst 'ix'
12538 Bug31490 Turkish: lcfirst 'BLAH'
12549 Bug31490 Turkish: ucfırst (with a dotless i)
12555 <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>
12560 Bug31490 ucfırst (with a dotless i) with English language
12566 <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>
12571 Bug 26375: TOC with italics
12573 title=[[Main Page]]
12576 == ''Lost'' episodes ==
12578 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
12580 <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>
12583 <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>
12588 Bug 26375: TOC with bold
12590 title=[[Main Page]]
12593 == '''should be bold''' then normal text ==
12595 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
12597 <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>
12600 <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>
12605 Bug 33845: Headings become cursive in TOC when they contain an image
12607 title=[[Main Page]]
12610 == Image [[Image:foobar.jpg]] ==
12612 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
12614 <li class="toclevel-1 tocsection-1"><a href="#Image"><span class="tocnumber">1</span> <span class="toctext">Image</span></a></li>
12617 <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>
12622 Bug 33845 (2): Headings become bold in TOC when they contain a blockquote
12624 title=[[Main Page]]
12627 == <blockquote>Quote</blockquote> ==
12629 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
12631 <li class="toclevel-1 tocsection-1"><a href="#Quote"><span class="tocnumber">1</span> <span class="toctext">Quote</span></a></li>
12634 <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>
12639 Unclosed tags in TOC
12641 title=[[Main Page]]
12645 <small>Hanc marginis exiguitas non caperet.</small>
12648 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
12650 <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>
12653 <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>
12654 <p><small>Hanc marginis exiguitas non caperet.</small>
12660 Multiple tags in TOC
12663 == <i>Foo</i> <b>Bar</b> ==
12665 == <i>Foo</i> <blockquote>Bar</blockquote> ==
12667 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
12669 <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>
12670 <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>
12673 <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>
12674 <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>
12679 Tags with parameters in TOC
12682 == <sup class="in-h2">Hello</sup> ==
12684 == <sup class="a > b">Evilbye</sup> ==
12686 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
12688 <li class="toclevel-1 tocsection-1"><a href="#Hello"><span class="tocnumber">1</span> <span class="toctext"><sup>Hello</sup></span></a></li>
12689 <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>
12692 <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>
12693 <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>
12698 span tags with directionality in TOC
12701 == <span dir="ltr">C++</span> ==
12703 == <span dir="rtl">זבנג!</span> ==
12705 == <span style="font-style: italic">The attributes on these span tags must be deleted from the TOC</span> ==
12707 == <span style="font-style: italic" dir="ltr">All attributes on these span tags must be deleted from the TOC</span> ==
12709 == <span dir="ltr" style="font-style: italic">Attributes after dir on these span tags must be deleted from the TOC</span> ==
12711 <table id="toc" class="toc"><tr><td><div id="toctitle"><h2>Contents</h2></div>
12713 <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>
12714 <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>
12715 <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>
12716 <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>
12717 <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>
12720 <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>
12721 <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>
12722 <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>
12723 <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>
12724 <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>
12731 == {{int:headline_sample}} ==
12735 Bug 32057: Title needed when expanding <h> nodes.
12737 title=[[Main Page]]
12741 <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>
12746 Strip marker in urlencode
12748 {{urlencode:x<nowiki/>y}}
12749 {{urlencode:x<nowiki/>y|wiki}}
12750 {{urlencode:x<nowiki/>y|path}}
12777 Strip marker in formatNum
12779 {{formatnum:1<nowiki/>2}}
12780 {{formatnum:1<nowiki/>2|R}}
12788 Check noCommafy in formatNum
12792 {{formatnum:123456.78}}
12793 {{formatnum:123456.78|NOSEP}}
12801 Strip marker in grammar
12805 {{grammar:elative|foo<nowiki/>bar}}
12812 Strip marker in padleft
12814 {{padleft:|2|x<nowiki/>y}}
12821 Strip marker in padright
12823 {{padright:|2|x<nowiki/>y}}
12830 Strip marker in anchorencode
12832 {{anchorencode:x<nowiki/>y}}
12839 nowiki inside link inside heading (bug 18295)
12841 ==[[foo|x<nowiki>y</nowiki>z]]==
12843 <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>
12848 new support for bdi element (bug 31817)
12850 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
12852 <p dir="rtl" lang="he">ולדימיר לנין (ברוסית: <bdi lang="ru">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>
12857 Ignore pipe between table row attributes
12861 |- id=foo | style='color: red'
12869 <tr id="foo" style="color: red">
12876 Gallery override link with WikiLink (bug 34852)
12879 File:foobar.jpg|caption|alt=galleryalt|link=InterWikiLink
12882 <ul class="gallery">
12883 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12884 <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>
12885 <div class="gallerytext">
12895 Gallery override link with absolute external link (bug 34852)
12898 File:foobar.jpg|caption|alt=galleryalt|link=http://www.example.org
12901 <ul class="gallery">
12902 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12903 <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>
12904 <div class="gallerytext">
12914 Gallery override link with malicious javascript (bug 34852)
12917 File:foobar.jpg|caption|alt=galleryalt|link=" onclick="alert('malicious javascript code!');
12920 <ul class="gallery">
12921 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12922 <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>
12923 <div class="gallerytext">
12933 Gallery with invalid title as link (bug 43964)
12936 File:foobar.jpg|link=<
12939 <ul class="gallery">
12940 <li class="gallerybox" style="width: 155px"><div style="width: 155px">
12941 <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>
12942 <div class="gallerytext">
12950 Language parser function
12959 Padleft and padright as substr
12961 {{padleft:|3|abcde}}
12962 {{padright:|3|abcde}}
12970 Bug 34939 - Case insensitive link parsing ([HttP://])
12972 [HttP://MediaWiki.Org/]
12974 <p><a rel="nofollow" class="external autonumber" href="HttP://MediaWiki.Org/">[1]</a>
12979 Bug 34939 - Case insensitive link parsing ([HttP:// title])
12981 [HttP://MediaWiki.Org/ MediaWiki]
12983 <p><a rel="nofollow" class="external text" href="HttP://MediaWiki.Org/">MediaWiki</a>
12988 Bug 34939 - Case insensitive link parsing (HttP://)
12990 HttP://MediaWiki.Org/
12992 <p><a rel="nofollow" class="external free" href="HttP://MediaWiki.Org/">HttP://MediaWiki.Org/</a>
12997 ### Parsoids-specific tests
12998 ### Parsoid-PHP parser incompatibilities
13001 1. SOL-sensitive wikitext tokens as template-args
13015 #### The following section of tests are primarily to test
13016 #### wikitext escaping capabilities of Parsoid.
13017 #### A lot of the tests are disabled for the PHP parser either
13018 #### because of minor newline diffs or other reasons.
13019 #### As Parsoid serializer can handle newlines and other HTML
13020 #### more robustly, some of these tests might get reenabled
13021 #### for the PHP parser.
13023 #### --------------- Headings ---------------
13025 #### 1. Nested inside html <h1>=foo=</h1>
13026 #### 2. Outside heading nest on a single line <h1>foo</h1>*bar
13027 #### 3. Nested inside html with wikitext split by html tags
13028 #### 4. No escape needed
13029 #### 5. Empty headings <h1></h1>
13030 #### 6. Heading chars in SOL context
13031 #### ----------------------------------------
13033 Headings: 0. Unnested
13035 <nowiki>=foo=</nowiki>
13037 <nowiki>=foo</nowiki>''a''=
13040 </p><p>=foo<i>a</i>=
13045 Headings: 1. Nested inside html
13049 =<nowiki>=foo=</nowiki>=
13050 ==<nowiki>=foo=</nowiki>==
13051 ===<nowiki>=foo=</nowiki>===
13052 ====<nowiki>=foo=</nowiki>====
13053 =====<nowiki>=foo=</nowiki>=====
13054 ======<nowiki>=foo=</nowiki>======
13065 Headings: 2. Outside heading nest on a single line <h1>foo</h1>*bar
13070 <nowiki>*bar</nowiki>
13074 <nowiki>=bar=</nowiki>
13082 Headings: 3. Nested inside html with wikitext split by html tags
13086 =<nowiki>=</nowiki>'''bold'''foo==
13088 <h1>=<b>bold</b>foo=</h1>
13092 Headings: 4. No escaping needed (testing just h1 and h2)
13107 <h1><i>=</i>foo=</h1>
13112 Headings: 5. Empty headings
13116 =<nowiki></nowiki>=
13117 ==<nowiki></nowiki>==
13118 ===<nowiki></nowiki>===
13119 ====<nowiki></nowiki>====
13120 =====<nowiki></nowiki>=====
13121 ======<nowiki></nowiki>======
13132 Headings: 6. Heading chars in SOL context
13136 <!--cmt--><nowiki>=h1=</nowiki>
13142 #### --------------- Lists ---------------
13143 #### 0. Outside nests (*foo, etc.)
13144 #### 1. Nested inside html <ul><li>*foo</li></ul>
13145 #### 2. Inside definition lists
13146 #### 3. Only bullets at start should be escaped
13147 #### 4. No escapes needed
13148 #### 5. No unnecessary escapes
13149 #### 6. Escape bullets in SOL position
13150 #### 7. Escape bullets in a multi-line context
13151 #### ----------------------------------------
13154 Lists: 0. Outside nests
13156 <nowiki>*foo</nowiki>
13158 <nowiki>#foo</nowiki>
13166 Lists: 1. Nested inside html
13168 *<nowiki>*foo</nowiki>
13170 *<nowiki>#foo</nowiki>
13172 *<nowiki>:foo</nowiki>
13174 *<nowiki>;foo</nowiki>
13176 #<nowiki>*foo</nowiki>
13178 #<nowiki>#foo</nowiki>
13180 #<nowiki>:foo</nowiki>
13182 #<nowiki>;foo</nowiki>
13204 Lists: 2. Inside definition lists
13206 ;<nowiki>;foo</nowiki>
13208 ;<nowiki>:foo</nowiki>
13210 ;<nowiki>:foo</nowiki>
13213 :<nowiki>:foo</nowiki>
13228 Lists: 3. Only bullets at start of text should be escaped
13230 *<nowiki>*foo*bar</nowiki>
13232 *<nowiki>*foo</nowiki>''it''*bar
13236 <ul><li>*foo<i>it</i>*bar
13242 Lists: 4. No escapes needed
13254 <ul><li><i>foo</i>*bar
13256 <ul><li><a href="Foo" rel="mw:WikiLink">Foo</a>: bar
13261 Lists: 5. No unnecessary escapes
13263 * bar <span><nowiki>[[foo]]</nowiki></span>
13265 *=bar <span><nowiki>[[foo]]</nowiki></span>
13267 *[[bar <span><nowiki>[[foo]]</nowiki></span>
13269 *<nowiki>]]bar </nowiki><span><nowiki>[[foo]]</nowiki></span>
13271 *=bar <span>foo]]</span>=
13273 <ul><li> bar <span>[[foo]]</span>
13275 <ul><li>=bar <span>[[foo]]</span>
13277 <ul><li>[[bar <span>[[foo]]</span>
13279 <ul><li>]]bar <span>[[foo]]</span>
13281 <ul><li>=bar <span>foo]]</span>=
13287 Lists: 6. Escape bullets in SOL position
13291 <!--cmt--><nowiki>*foo</nowiki>
13298 Lists: 7. Escape bullets in a multi-line context
13308 #### --------------- HRs ---------------
13309 #### 1. Single line
13310 #### -----------------------------------
13313 HRs: 1. Single line
13318 <nowiki>----</nowiki>
13320 <nowiki>=foo=</nowiki>
13322 <nowiki>*foo</nowiki>
13329 #### --------------- Tables ---------------
13330 #### 1a. Simple example
13331 #### 1b. No escaping needed (!foo)
13332 #### 1c. No escaping needed (|foo)
13333 #### 1d. No escaping needed (|}foo)
13335 #### 2a. Nested in td (<td>foo|bar</td>)
13336 #### 2b. Nested in td (<td>foo||bar</td>)
13337 #### 2c. Nested in td -- no escaping needed(<td>foo!!bar</td>)
13339 #### 3a. Nested in th (<th>foo!bar</th>)
13340 #### 3b. Nested in th (<th>foo!!bar</th>)
13341 #### 3c. Nested in th -- no escaping needed(<th>foo||bar</th>)
13345 #### 4c. No escaping needed
13346 #### --------------------------------------
13349 Tables: 1a. Simple example
13360 Tables: 1b. No escaping needed
13369 Tables: 1c. No escaping needed
13378 Tables: 1d. No escaping needed
13387 Tables: 2a. Nested in td
13392 |<nowiki>foo|bar</nowiki>
13402 Tables: 2b. Nested in td
13407 |<nowiki>foo||bar</nowiki>
13408 |''it''<nowiki>foo||bar</nowiki>
13413 </td><td><i>it</i>foo||bar
13419 Tables: 2c. Nested in td -- no escaping needed
13434 Tables: 3a. Nested in th
13449 Tables: 3b. Nested in th
13454 !<nowiki>foo!!bar</nowiki>
13464 Tables: 3c. Nested in th -- no escaping needed
13479 Tables: 4a. Escape -
13487 |<nowiki>-bar</nowiki>
13491 <tr><th>-bar</th></tr>
13492 <tr><td>-bar</td></tr>
13497 Tables: 4b. Escape +
13505 |<nowiki>+bar</nowiki>
13509 <tr><th>+bar</th></tr>
13510 <tr><td>+bar</td></tr>
13515 Tables: 4c. No escaping needed
13529 <tr><td>foo-bar</td><td>foo+bar</td></tr>
13530 <tr><td><i>foo</i>-bar</td><td><i>foo</i>+bar</td></tr>
13535 Tables: 4d. No escaping needed
13551 #### --------------- Links ---------------
13552 #### 1. Quote marks in link text
13553 #### 2. Wikilinks: Escapes needed
13554 #### 3. Wikilinks: No escapes needed
13555 #### 4. Extlinks: Escapes needed
13556 #### 5. Extlinks: No escapes needed
13557 #### --------------------------------------
13559 Links 1. Quote marks in link text
13563 [[Foo|<nowiki>Foo''boo''</nowiki>]]
13565 <a rel="mw:WikiLink" href="Foo">Foo''boo''</a>
13569 Links 2. WikiLinks: Escapes needed
13573 [[Foo|<nowiki>[Foobar]</nowiki>]]
13574 [[Foo|<nowiki>Foobar]</nowiki>]]
13575 [[Foo|<nowiki>x [Foobar] x</nowiki>]]
13576 [[Foo|<nowiki>x [http://google.com g] x</nowiki>]]
13577 [[Foo|<nowiki>[[Bar]]</nowiki>]]
13578 [[Foo|<nowiki>x [[Bar]] x</nowiki>]]
13579 [[Foo|<nowiki>|Bar</nowiki>]]
13581 <a href="Foo" rel="mw:WikiLink">[Foobar]</a>
13582 <a href="Foo" rel="mw:WikiLink">Foobar]</a>
13583 <a href="Foo" rel="mw:WikiLink">x [Foobar] x</a>
13584 <a href="Foo" rel="mw:WikiLink">x [http://google.com g] x</a>
13585 <a href="Foo" rel="mw:WikiLink">[[Bar]]</a>
13586 <a href="Foo" rel="mw:WikiLink">x [[Bar]] x</a>
13587 <a href="Foo" rel="mw:WikiLink">|Bar</a>
13591 Links 3. WikiLinks: No escapes needed
13598 <a href="Foo" rel="mw:WikiLink">[Foobar</a>
13599 <a href="Foo" rel="mw:WikiLink">foo|bar</a>
13603 Links 4. ExtLinks: Escapes needed
13607 [http://google.com <nowiki>[google]</nowiki>]
13608 [http://google.com <nowiki>google]</nowiki>]
13610 <a href="http://google.com" rel="mw:ExtLink">[google]</a>
13611 <a href="http://google.com" rel="mw:ExtLink">google]</a>
13615 Links 5. ExtLinks: No escapes needed
13619 [http://google.com [google]
13621 <a href="http://google.com" rel="mw:ExtLink">[google</a>
13624 #### --------------- Quotes ---------------
13625 #### 1. Quotes inside <b> and <i>
13626 #### 2. Link fragments separated by <i> and <b> tags
13627 #### 3. Link fragments inside <i> and <b>
13628 #### --------------------------------------
13630 1. Quotes inside <b> and <i>
13632 ''<nowiki>'foo'</nowiki>''
13633 ''<nowiki>''foo''</nowiki>''
13634 ''<nowiki>'''foo'''</nowiki>''
13635 '''<nowiki>'foo'</nowiki>'''
13636 '''<nowiki>''foo''</nowiki>'''
13637 '''<nowiki>'''foo'''</nowiki>'''
13638 '''<nowiki>foo'</nowiki>''<nowiki>bar'</nowiki>''baz'''
13646 <b>foo'<i>bar'</i>baz</b>
13651 2. Link fragments separated by <i> and <b> tags
13653 [[''foo''<nowiki>hello]]</nowiki>
13655 [['''foo'''<nowiki>hello]]</nowiki>
13657 <p>[[<i>foo</i>hello]]
13658 </p><p>[[<b>foo</b>hello]]
13663 2. Link fragments inside <i> and <b>
13664 (FIXME: Escaping one or both of [[ and ]] is also acceptable --
13665 this is one of the shortcomings of this format)
13667 ''[[foo''<nowiki>]]</nowiki>
13669 '''[[foo'''<nowiki>]]</nowiki>
13672 </p><p><b>[[foo</b>]]
13676 #### --------------- Paragraphs ---------------
13677 #### 1. No unnecessary escapes
13678 #### --------------------------------------
13681 1. No unnecessary escapes
13683 bar <span><nowiki>[[foo]]</nowiki></span>
13685 =bar <span><nowiki>[[foo]]</nowiki></span>
13687 [[bar <span><nowiki>[[foo]]</nowiki></span>
13689 <nowiki>]]bar </nowiki><span><nowiki>[[foo]]</nowiki></span>
13691 <nowiki>=bar </nowiki><span>foo]]</span>=
13693 <p>bar <span>[[foo]]</span>
13694 </p><p>=bar <span>[[foo]]</span>
13695 </p><p>[[bar <span>[[foo]]</span>
13696 </p><p>]]bar <span>[[foo]]</span>
13697 </p><p>=bar <span>foo]]</span>=
13701 #### --------------- PRE ------------------
13702 #### 1. Leading space in SOL context should be escaped
13703 #### --------------------------------------
13705 1. Leading space in SOL context should be escaped
13709 <nowiki> foo</nowiki>
13710 <!--cmt--><nowiki> foo</nowiki>
13717 #### --------------- HTML tags ---------------
13720 #### 3. multi-line html tag
13721 #### --------------------------------------
13727 <a href="http://google.com">google</a>
13729 <a href="http://google.com">google</a>
13735 <nowiki><div>foo</div>
13736 <div style="color:red">foo</div></nowiki>
13738 <p><div>foo</div>
13739 <div style="color:red">foo</div>
13744 3. multi-line html tag
13756 #### --------------- Others ---------------
13760 <nowiki>foo</nowiki>
13762 <p><nowiki>foo</nowiki>
13767 Tag-like HTML structures are passed through as text
13789 </p><p>1<d e>f
13794 # This fails in the PHP parser (see bug 40670,
13795 # https://bugzilla.wikimedia.org/show_bug.cgi?id=40670), so disabled for it.
13797 Tag names followed by punctuation should not be recognized as tags
13803 <p><s.ome> text
13808 HTML tag with necessary entities in attributes
13810 <span title="&amp;">foo</span>
13812 <p><span title="&amp;">foo</span>
13817 HTML tag with 'unnecessary' entity encoding in attributes
13819 <span title="&">foo</span>
13821 <p><span title="&">foo</span>
13826 HTML tag with broken attribute value quoting
13828 <span title="Hello world>Foo</span>
13830 <p><span>Foo</span>
13835 Parsoid-only: HTML tag with broken attribute value quoting
13839 <span title="Hello world>Foo</span>
13841 <p><span title="Hello world">Foo</span>
13846 Table with broken attribute value quoting
13849 | title="Hello world|Foo
13860 Table with broken attribute value quoting on consecutive lines
13863 | title="Hello world|Foo
13864 | style="color:red|Bar
13877 Parsoid-only: Table with broken attribute value quoting on consecutive lines
13882 | title="Hello world|Foo
13883 | style="color:red|Bar
13888 <td title="Hello world">Foo
13889 </td><td style="color: red">Bar
13895 Accept empty td cell attribute
13898 | align="center" | foo || |
13903 <td align="center"> foo </td>
13910 Non-empty attributes in th-cells
13913 ! Foo !! style="color: red" | Bar
13919 <th style="color: red"> Bar
13925 Accept empty attributes in th-cells
13940 Empty table rows go away
13965 Try for 100% code coverage