[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Creating frames, bookmarks, TOC using 1 stylesheet
Hi Nazrul, > Can I create a page with 2 frames and put the TOC on the left side > and the contents on the right side that links to each other based on > the bookmarks using only 1 stylesheet? Yes and no. The 'no' is that HTML does not allow you to embed the content of a frame within the definition of a frame - they have to be from separate files. But each run of an XSLT 1.0 stylesheet without any extensions can only produce one document at a time. So you cannot create two frames from the same stylesheet at the same time if you're using XSLT 1.0. The 'yes' is that there are extension elements like exsl:document, saxon:output or xalan:redirect that allow you to create more than one document from one run of the stylesheet. So you could create both frames from one run of the stylesheet, and create a frameset document that references those two frames. This way of doing things is best if you're using static XSLT, i.e. in a batch process. The other 'yes' is that you can use the same stylesheet to give you two different types of output based on a parameter value. So you could use a script to manage applying the stylesheet first to get the ToC, then to get the content, and populate the frames accordingly. This works if you're doing client-side transformation. I should point out that from the code that you posted it looks as though you're using the old Microsoft-specific dialect rather than XSLT 1.0. Have a look at the MSXML FAQ at http://www.netcrucible.com/xslt/msxml-faq.htm to learn more about the differences. I hope that helps, Jeni --- Jeni Tennison http://www.jenitennison.com/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|