M. David Peterson wrote:
Hey Robert,
Robert Koberg wrote:
Hi,
I have added some XSL transformation conveniences to the dojo toolkit
(http://dojotoolkit.org - you would need to use SVN and get the trunk)
WOW! I hadn't realized how big Dojo had become. I've got the
repository checked out. Where can I find your extensions?
Dojo is pretty cool :) Docs kinda suck. The dojo.xml.XslTransform class
is in: dojo/src/xml. Be sure to check out
dojo/tests/xml/test_XslTransform.html for some different uses.
Basically, the public API (I am open to change or extend it to make it
more useful) looks like:
dojo.xml.XslTransform = function(/*String*/ xsltUri) {
/*
Common params:
xmlDoc - the primary XML source
params - a 2 dim array, e.g. [[name, value]] which is cleared after each
transform
parentDoc - the window.document that is the parent of the result
*/
this.getResultString = function(/*XMLDOcument*/ xmlDoc, /*2 Dimensional
Array*/params, /*HTMLDocument*/parentDoc)
/*
contentPane - dojo specific layout region to put the result into
(instatiates child widgets)
*/
this.transformToContentPane = function(/*XMLDOcument*/ xmlDoc, /*2
Dimensional Array*/params, /*ContentPane*/contentPane,
/*HTMLDocument*/parentDoc);
/*
region - some HTML element to put the result into
*/
this.transformToRegion = function(/*XMLDOcument*/ xmlDoc, /*2
Dimensional Array*/params, /*HTMLElement*/region,
/*HTMLDocument*/parentDoc);
this.transformToDocument = function(/*XMLDOcument*/ xmlDoc, /*2
Dimensional Array*/params);
this.transformToWindow = function(/*XMLDOcument*/ xmlDoc, /*2
Dimensional Array*/params, /*HTMLDocument*/windowDoc,
/*HTMLDocument*/parentDoc);
}
best,
-Rob
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--