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

RE: Problem using Muenchian method (apply-templates or

Subject: RE: Problem using Muenchian method (apply-templates or key) with MSXML 3.0 & 4.0
From: "Kirk Allen Evans" <kaevans@xxxxxxxxxxxxx>
Date: Mon, 20 May 2002 13:02:20 -0400
method.apply
-----Original Message-----
From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx
[mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx]On Behalf Of Saldate,
DanielX
Sent: Monday, May 20, 2002 11:36 AM
To: XSL List (E-mail)
Subject:  Problem using Muenchian method (apply-templates or key)
with MSXML 3.0 & 4.0

> I've run into an interesting problem with MSXML 3.0 SP2 and 4.0 SP1.  This
> seems to be related to invoking either of these parsers from code, but I'm
> not absolutely sure yet.

> I have an XML data island embedded into a web page that looks somewhat
like
> the XML pasted below.



Remove the XML node in your stylesheet's XPath statements.  Using the
following code,

	<html>
	<xml id="XMLData">
		<foo>
			<bar>test</bar>
		</foo>
	</xml>

	<script language="javascript">
		function myfunc()
		{
			var doc = new ActiveXObject("Microsoft.XMLHTTP");
			xmlHTTP.Open ("POST", "MyPage.asp", false);
			xmlHTTP.Send (XMLData.xml);
		}
	</script>

	<body onload="javascript:myfunc()">
	</body>
	</html>

Only the elements "foo" and "bar" and the child text node are transmitted:
the "xml" tag is a client-side identifier and is not part of the XML
structure.  So, the document node is being matched, giving you the HTML
result in the root template match, but none of the other XML data can be
matched because there is no "XML" node in the document.


Kirk Allen Evans
"XML and ASP.NET", New Riders Publishing
Available at Amazon.com
http://www.amazon.com/exec/obidos/ASIN/073571200X



 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.