RE: [xsl] Conditional extraction of data

Subject: RE: [xsl] Conditional extraction of data
From: "Bradley, Peter" <PBradley@xxxxxxxxxx>
Date: Tue, 9 Nov 2004 08:37:47 -0000
Morning all.  I don't want this to go on for so long that you get bored with
it, but I thought you all, and especially Wendell, would like to know that I
awoke at 04:10 this morning to the sound of a very large penny dropping onto
what appeared to be an equally large landmine.

Of course!  To simply pass through all the content in the data file, all I
need is:

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
version="1.0">
</xsl:stylesheet>

The recursive processing; the default templates; these will take care of the
rest.

I suspect I'm going to find the rest of the exercises quite a bit easier now.
Pity I have to completely re-write my submission, but there you go.  Can't
have everything.

Thanks to you all.  I would never have got here without you.  Oh, and by the
way, my tutor has confirmed that it was OK to contact the mailing list (even
complementing me on my "professional honesty", which I'm sure I don't
deserve).

So happy endings all round really.

Cheers

Peter


 -----Original Message-----
From: 	Wendell Piez [mailto:wapiez@xxxxxxxxxxxxxxxx]
Sent:	08 November 2004 18:38
To:	xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject:	Re: [xsl] Conditional extraction of data

Hi,

Respectfully, I'd like to suggest you guys are all giving Peter very useful
information, which is only likely to confuse him, despite (and even
exacerbated by) the occasional "aha"!

The solution to his problem is in mastering templates and the recursive
template-based processing model, operating over the tree (not the "tags",
as David warns). If he understands this, there are a million ways for him
to solve his problem (and one very simple, elegant and obvious way). If he
doesn't, he'll try all the other stuff (copy-of, value-of, etc etc) and
sometimes get what he wants but sometimes not -- never understanding why.

This is only more true of subsequent exercises in the assignment.

Peter, figure out what "apply-templates" does (what does this mean and what
is it applying templates to?) and everything else will fall into place.
This is the secret of handling mixed content (elements intermixed
arbitrarily with text).

Cheers,
Wendell


======================================================================
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