There's a difference between backend complexity and complexity for the user.
On 8/10/06, Simetrical Simetrical+wikitech@gmail.com wrote:
On 8/10/06, Steve Bennett stevage@gmail.com wrote:
Ok, you're treating wikisyntax and HTML as essentially equivalent. Which they're not.
Some are, some aren't. Note "beyond what actually needs to be parsed beyond sanitization". Internal links must be parsed beyond sanitization, e.g., to generate what-links-here. Since they're so common, it might make sense to keep them separate from the HTML that they generate. That would be a specific decision that would have to be made. But the following can certainly all be dispensed with in favor of XHTML:
horizontal rule initial space (= <pre>) wikilists wikitables headings external links (probably) italics/bold everything newline-related (conversions should be dealt with on edit, not on render) HTML that's invalid XML
That's already what, probably cut the number of rules needed by a factor of three? More? Then, in fact, just convert all remaining markup to XML, and you can handle all parsing via library functions, whether in PHP or Javascript or C or anywhere else.
Wikisyntax is definitely "cleaner" than HTML and closer to the semantic representation of what we want to store. Storing only HTML (or XHTML) really ties us to a pretty specific presentation platform.
The above list consists exclusively of things that have a one-to-one mapping with HTML tags.
The more practical approach to me would be to layer an increasingly powerful GUI over the top that allows the user to edit most wikisyntax without even seeing it.
The problem is the complexity of the wikimarkup. Look at http://www.mediawiki.org/wiki/Markup_spec for how many rules are needed on top of the SGML parsing that we need anyway. A Javascript app that could parse all that in real time without noticeable lag would probably be very difficult to impossible to write. And it's also led pretty directly to the slowness and complexity of our current parser, too. It's all unnecessary: the markup doesn't need to be easily human-readable if we have WYSIWYG. _______________________________________________ Wikitech-l mailing list Wikitech-l@wikimedia.org http://mail.wikipedia.org/mailman/listinfo/wikitech-l