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

RE: nested XML using xslt

Subject: RE: nested XML using xslt
From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx>
Date: Fri, 24 Jul 2009 10:43:04 -0400
RE:  nested XML using xslt
Hi,

Also, as an earlier respondent noticed, it's impossible to answer this question without specifying the source data on which the stylesheet must operate.

The confusing thing is that the OP spoke of having to generate nested structures, but the templates in his code matched structures with the same names as his presumed output.

So which is it: generating nested structures from some (unstated) input, or processing nested structures -- or mapping one nested structure to another? Any of these may be trivially easy in XSLT, but they aren't the same.

Following the list guidelines and providing illustrations of both source and intended result would be a big help here.

Cheers,
Wendell

At 07:05 PM 7/23/2009, Mike wrote:
> The trick is to make sure that the first list3 gets closed
> after <list4> , and a new <list3> opens after the first closes.

It's too late at night for me to understand your problem, but this sentence
sounds as if you're approaching it from the wrong angle.

Don't think in terms of opening and closing elements. Think in terms of
constructing a tree of nodes. Writing an element is an atomic operation, it
isn't two separate operations to write the start and end tags. Draw the
result tree you want to produce on a scrap of paper - as a tree - and keep
it in front of you while coding; don't think about the serialized XML
output.


======================================================================
Wendell Piez                            mailto:wapiez@xxxxxxxxxxxxxxxx
Mulberry Technologies, Inc.                http://www.mulberrytech.com
17 West Jefferson Street                    Direct Phone: 301/315-9635
Suite 207                                          Phone: 301/315-9631
Rockville, MD  20850                                 Fax: 301/315-8285
----------------------------------------------------------------------
  Mulberry Technologies: A Consultancy Specializing in SGML and XML
======================================================================

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.