Difference between revisions of "XmlWiki"
Line 6: | Line 6: | ||
Articles in xmlWiki work just like the normal MediaWiki articles except, when their contents is xml. In this case it will be represented as a DOM object at runtime, and the content will be validated against any referenced DTD or xml-schema. If any XSLT's are referenced, xmlWiki will attempt to apply them to the article. If the XSLT-output-method is "html" then it will be reduced to a string. | Articles in xmlWiki work just like the normal MediaWiki articles except, when their contents is xml. In this case it will be represented as a DOM object at runtime, and the content will be validated against any referenced DTD or xml-schema. If any XSLT's are referenced, xmlWiki will attempt to apply them to the article. If the XSLT-output-method is "html" then it will be reduced to a string. | ||
+ | ==How is it Installed?== | ||
+ | It's three scripts (source below) which are in an "xmlwiki" directory in the main wiki folder. the hack is applied or removed by running the xmlwiki/index.php script. If xmlWiki is disabled then the security layer is also disabled, so the xmlwiki directory should be accessible only by admin. | ||
+ | |||
==How does it tie in with MediaWiki?== | ==How does it tie in with MediaWiki?== | ||
Two pseudo-namespaces have been added "xml" and "sys". These are both XML articles, and their contents affects the article they're associated with. Any sys:article is readable and writable only by users in the "admin" group. | Two pseudo-namespaces have been added "xml" and "sys". These are both XML articles, and their contents affects the article they're associated with. Any sys:article is readable and writable only by users in the "admin" group. |
Revision as of 00:24, 10 June 2005
File:Xmlwiki old.jpg Old logo: File:Xmlwiki wht.jpg
Contents
What is xmlWiki?
Articles in xmlWiki work just like the normal MediaWiki articles except, when their contents is xml. In this case it will be represented as a DOM object at runtime, and the content will be validated against any referenced DTD or xml-schema. If any XSLT's are referenced, xmlWiki will attempt to apply them to the article. If the XSLT-output-method is "html" then it will be reduced to a string.
How is it Installed?
It's three scripts (source below) which are in an "xmlwiki" directory in the main wiki folder. the hack is applied or removed by running the xmlwiki/index.php script. If xmlWiki is disabled then the security layer is also disabled, so the xmlwiki directory should be accessible only by admin.
How does it tie in with MediaWiki?
Two pseudo-namespaces have been added "xml" and "sys". These are both XML articles, and their contents affects the article they're associated with. Any sys:article is readable and writable only by users in the "admin" group.
- The sys:article holds security information: owner, read-groups, write-groups
- An xml:article is an XML article of docType "xmlwiki.dtd"
- The xml:article contains the transform-list, publish-list and base-class-list
More Specifically
It hooks itself into the MediaWiki index.php file in three places and also creates a new compulsory skin called xwSkin.php in /skins. The index.php hooks are INIT, which is called on entry to require_once it, then INPUT, which is called before the POST-data is processed for saving, and finally OUTPUT, which is called instead of the wiki-page-render. The xwSkin skin builds the output as a DOM-object which is then transformed with the users (or default) XSLT-skin by the OUTPUT hook.
Current scripts:
Templates & Transforms
- here.