Can I please ask a unusual question: Is there some way to get
MediaWiki to render a page from just the wiki source, and no database?
I.e.:
Input: wiki string (e.g. This ''is'' a '''test'''.
[[Axiom]]atic.
[[Wiki Web|test]].")
Output: HTML string (e.g. "<p>This <i>is</is> a
<b>test</b>. <a
href="?Axiom">Axiomatic</a>. <a
href="?Wiki_Web">test</a>.</p>").
Is there some way to do this using the MediaWiki software? Ideally I
want just the wiki rendering engine, without any of the other stuff,
and without having to delve deeply into the internals of how MediaWiki
works.
I'm happy for all links to either be edit links or not (i.e. no reason
to check whether a page exists or not). Also happy for any templates
or other inclusions in wiki strings to be ignored, so it's a straight
string transformation, and so that there should be no reason to
connect to or use a database.
The reason I'm asking is I'm trying to scope out if it's possible to
pass in the wiki source of an article, convert it to HTML, and then
HTML validate that output, so as to find invalid HTML and mis-uses of
HTML in wiki articles.
( Erik Zachte did something along these lines previously with invalid
<table> attributes - please see
http://en.wikipedia.org/w/index.php?title=Wikipedia:WikiProject_Wiki_Syntax…
for some examples of output that he found previously that have been
fixed ).
All the best,
Nick.