ASP Error: 70
Description: Permission denied
Source: Microsoft VBScript runtime error

[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: using the mozilla xsl rendering engine

Subject: Re: using the mozilla xsl rendering engine
From: Mitch Amiano <mitch.amiano@xxxxxxxxxxxxxxxxxxxx>
Date: Sun, 29 Dec 2002 18:41:41 -0500
mozilla xsl
Near as I can figure it, some builds may mistakenly use the obsolete XSLTProcessor interface instead of the newer one. I've got Mozilla 1.2b, which *should* use the newer interfaces, but doesn't.

You can add variables and parameters to a stylesheet DOM using Javascript.

If, for instance,
 parameters = { foreground: "#FF0000", background: "#00FF00" };

for ( pname in parameters )
{
var p = stylesheet.createElementNS("http://www.w3.org/1999/XSL/Transform","variable");
p.setAttribute("name", pname);
p.appendChild(stylesheet.createTextNode( parameters[pname] ));
stylesheet.childNodes[1].insertBefore( p , stylesheet.childNodes[1].firstChild
);
}


This is sloppy, but I hope you get the idea. It doesn't check to see if there are any variables by the same name already defined in the stylesheet. (If they aren't already defined and you don't add them, it is an error which Transformix doesn't pick up on.) Also, childNodes[0] of the stylesheet is a text fragment; I don't know why or whether this is documented, but it doesn't seem right. It is probably whitespace.

juggy@xxxxxxx wrote:

Hi Jarno,

Of course I meant XSLT implementation - sorry, that was a little bit misleading. :-)
Thank you very much for the link. I have seen it before though and tried it out a little bit, but I didn't get it to work right. Do you know of an example of working code? I might be able to find out my mistakes that way.


Thanks!

Juggy

Jarno.Elovirta@xxxxxxxxx wrote:

Hi,


I am trying to
1.) combine several xml-files into 1
2.) pass a parameter to an xsl stylesheet
3.) select a certain node according to the stylesheet

(1) is working alright, but I just cannot seem to find a solution to (2). (3) should be easy afterwards.
I usually use saxon/xalan for stuff like this, but in this case I would really rather have it done by the Mozilla rendering engine. I think I



You probably mean the XSLT implementation in Mozilla, not the rendering engine.



need to do some javascript tinkering or such - has anybody ever done something like this?



See


--

Jarno - Dulce Liquido: Disolucion

XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list




XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list





XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list



Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.