xsl-list
[Top] [All Lists]

RE: Exsl functions in xslt 2

2004-01-20 01:40:39

  I tried this but of course got problems with data typing.  I tried
  having a stylesheet with version="2.0" import a stylesheet with
  version="1.0" and vice versa, but both produced the same 
set of errors
  (with Saxon 7.8).


Don't blame me:-)

seriously, You could consider making a comment to the 
official xslt2 comment list outlining where backward 
compatibility isn't compatible enough. I'm sure real examples 
are helpful to them at this stage.


....but msxml4 complains about the 'xs:' namespace.
You could define javascript  xs:integer() and xs:string () in 
the xs namespace using msxsl:script

But actually don't the xpath 1 (and 2) functions number() and 
string() avoid these errors:

  Required type of first argument of format-number() is 
number; supplied
  value has type xs:string

  and

  Required type of first argument of concat() is xs:string; supplied
  value has type xs:integer

so you could use number() rather than xs:integer and it 
should work in xslt1 shouldn't it?

It does, works like a charm (far too obvious! :) 

Thanks,

andrew

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



<Prev in Thread] Current Thread [Next in Thread>