I am trying to use xsl tranformation the create a dTree menu with the xml generated with the ?readentries url command for outlines. I am just trying to see if this will work and the menu I am building is hard coded in the xsl file. When I load the form I see nothing, but if I view the page source I can see the div is populated like I expected. I assume that I am missing something to do with trying to use . Can I us with xsl?
Here is my xsl:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:template match=“/”>
a = new dTree('a');
a.config.useCookies=false;
a.add(0,-1,'Tree example','javascript: void(0);');
a.add(1, 0,'Node 1','javascript:void(0);');
document.write(a);
</script>
</xsl:template> </xsl:stylesheet>
Subject: Need a little xsl help
Not sure what your trying to do here or why you want to use XSLT to create a dTree menu. The last version of dTree I have used did not in any way make use of or benefit from XML/XSL.
Also, you didn’t mention yet, if you want to use client-side or server-side XSLT. The good news is: It doesn’t matter, your JavaScript-within-XSL approach will work in neither scenario. Since the Domino server doesn’t speak JavaScript, server-side processing is ruled out. But even in the browser it will not work, because the JavaScript will not be executed. The source code will become the literal contents of your XSL file. For client-side XSLT to work, the XSL file must be served to the browser as readily build valid XML.
Subject: RE: Need a little xsl help
My end goal was to greate the dTree menu based on an notes outline. I just had the dtree code “hard coded” for testing, to see if this could be done. I did not get as far as getting values from an outline xml.
Subject: RE: Need a little xsl help
What I once did for that purpose was to have a LotusScript agent reading the outline entries and populate some configuration document (or profile documen, I don’t remember the details) with the stuff needed in dTree. The on a form or page I used a computed text to retrieve this info in a pass-through HTML section containing my dTree script.
No cool and new technology, plus the agent has to be run manually after each change to the outline or scheduled, but it did work. Could well be, that there is a much better approach using DXL, but not by putting JS inside XML. I think I started this back on R5, so my advice could be a little outdated.