Re: [xsl] Using XSLT parameters with ASP

Subject: Re: [xsl] Using XSLT parameters with ASP
From: Dimitre Novatchev <dnovatchev@xxxxxxxxx>
Date: Tue, 30 Jan 2001 12:16:07 -0800 (PST)
Hi Glen,

Below is a simple example:

  var objStylesheetParam   =

  objStylesheetParam.setAttribute("select", yourParameterValue);

  // Repeat the above for as many xsl:param-s as necessary

  source.transformNodeToObject(style, Response);

Hope this helped,

Dimitre Novatchev.

Mazza, Glen wrote:

Given Jeni's sample parameter of "<xsl:param name = "foo" />" within my
file, and the Microsoft example of doing ASP translation:

<%@ LANGUAGE = JScript %>
  // Set the source and style sheet locations here
  var sourceFile = Server.MapPath("sample.xml");
  var styleFile = Server.MapPath("sample.xsl");
  // Load the XML 
  var source = Server.CreateObject("Msxml2.DOMDocument");
  source.async = false;

  // Load the XSL
  var style = Server.CreateObject("Msxml2.DOMDocument");
  style.async = false;

  source.transformNodeToObject(style, Response);


How do I pass in the value of the foo parameter, before calling

Get personalized email addresses from Yahoo! Mail - only $35 
a year!

 XSL-List info and archive:

Current Thread