xsl-list
[Top] [All Lists]

Re: reference external javascript file with msxml parser

2003-04-05 10:29:18
Mac,

I believe that your question is more of an HTML question rather than an XSL
or XML question.  Assuming your output is HTML, you should be able to use
the html convention for an externally linked javascript file.  Something
like this should suffice:

<xsl:element name="script">
  <xsl:attribute name="language">JScript</xsl:attribute>
  <xsl:attribute name="src">path/to/your/jscript/file</xsl:attribute>
</xsl:element>

If your file was located in c:/temp, pure html would look something like
this:

<script language="JScript" src="c:/temp/jscriptFile.js"></script>

Hope that helps!
bix



----- Original Message -----
From: "Mac Martine" <email(_at_)magusdesigns(_dot_)com>
To: <xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com>
Sent: Friday, April 04, 2003 5:01 PM
Subject: [xsl] reference external javascript file with msxml parser



Hello-
 I basically need the following, except I want the javascript to be in
an external file. How can I do this? Thanks-
 Mac

<msxsl:script language="JScript" implements-prefix="my">
  function test() {
    return 1;
  }
</msxsl:script>


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



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