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

Re: Dynamic processing of xml file using xsl and java

Subject: Re: Dynamic processing of xml file using xsl and javascript (200411/msg00765)
From: "Alan Varga" <aevarga@xxxxxx>
Date: Mon, 31 Oct 2005 07:02:57 -0600
sarissa transformtodocument
Manos,

I am still having trouble transforming my XML file with Sarissa.  To
simplify things, I stripped the HTML document of everything but the section
where I want the data to appear.  Here is newsarissatest.js:

---------------------------------------
var processor = new XSLTProcessor();
var xslDoc = Sarissa.getDomDocument("Band-Cadet.xsl");
processor.importStylesheet(xslDoc);
var xmlDoc = Sarissa.getDomDocument("calendar.xml");
var newDocument = processor.transformToDocument(xmlDoc);
alert(Sarissa.serialize(newDocument));
---------------------------------------

and here is band.htm:

---------------------------------------
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
  "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
  xml:lang="en">
<head>
<meta http-equiv="Content-Type"
  content="text/html; charset=utf-8" />
<link type="text/css"
      rel="stylesheet"
      media="screen, print"
      href="mmsbb3.css" />
<title></title>
</head>

<body>
<div id="calbody">
<script type="text/javascript"
        src="newsarissatest.js"></script>
</div>

</body>
</html>
---------------------------------------


Again, since I am a hobbyist, I didn't plan on getting deep into the DOM.  I
do have code other than Sarissa which works in IE and almost works in FF,
but since Sarissa seems to be widely accepted I wanted to use it because of
better support.

Thanks, Alan

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.