RE: [xsl] converting xsl-wd to xsl1, msxml script changes

Subject: RE: [xsl] converting xsl-wd to xsl1, msxml script changes
From: Woody <woody@xxxxxxxxxxxxxx>
Date: Wed, 12 Feb 2003 22:39:21 +0000
I am sure there is an xsl way of doing this but this has been replaced
by javascript for speed.

Do you mean that you want it to be javascript or would you accept an xslt solution for it?

I have worked out the xslt solulution to it (I think) but realised that I had not spotted the real problem with it. There isn't anything wrong with the javascript, the problem is the variable passed to it.

If I query the object I was sent it is an 'object' when I really want a node.

I am calling it with <xsl:value-of select="msxml:transform('.')"/>

and I am trying to get the node set of the object - I don't know what it is I am getting and I am having difficulty finding it out. (I have also tried sending it different things, putting it in a variable, putting msxsl:node-set.. etc)

A propos the javascript for speed I think Dimitre Novatchev showed that
the javascript was in fact slower in his implementation of a random
number generator for his fxsl project, although this may be just my
memory playing tricks on me.

I don't know, I am new at this but I do know there is a comment in the file from a few years ago which says the xsl version was replaced by the javascript version for a 7 times speed increase, and there is timing code in there. maybe it is different now but my concern is that I have many of these files that I want to convert and they all have the same node passing problem.

Microsoft had a wd-xsl to xslt convertor written in(I think) xslt at one
time, however as with all automatic conversion processes the converted
xslts were less than optimal.

I tried that, the input file was 7k, the output file was over 80k and consisted of mainly comments saying I had to rewrite it.. clever I thought :)

It might be good to say what these
functions do and take it from there.

The structure of large parts of the xml is similar to parts of the html so it does a regular expresion searchand replace and writes it out as a string.
hopefully I won't have to touch that bit.. me and regular expressions never got on


XSL-List info and archive:

Current Thread