comp.lang.ada
 help / color / mirror / Atom feed
From: Georg Bauhaus <sb463ba@l1-hrz.uni-duisburg.de>
Subject: Re: Experiences of XML parser generators for Ada?
Date: Mon, 6 Dec 2004 11:18:19 +0000 (UTC)
Date: 2004-12-06T11:18:19+00:00	[thread overview]
Message-ID: <cp1f5r$aed$1@a1-hrz.uni-duisburg.de> (raw)
In-Reply-To: 9936151.FNPvfK1bZX@linux1.krischik.com

Martin Krischik <martin@krischik.com> wrote:
: Georg Bauhaus wrote:
: 
:>
:>   <issue-date   year="2003"  month="4" day="31" />
: 
: But was not the idea of XML that - by using an appropriate CSS - the data
: can be rendered by a browser for easy reading? And don't you need to
: seperate data from markup to archive that:

The idea of XML, and of *separating* markup from format, predates
both HTML and CSS. (And note how the required "alt" attribute of the
HTML "img" tag is rendered by many browsers...)

Usually, a style sheet and an XML document instance _are_ separate,
they can be combined freely using one processing instruction.

: <issue-date><year>2003</year><month>4</month><day>31</day></issue-date>

If, for some reason (other than related to rendering), you need to
transform your data into the line above (and not into HTML for rendering),

  <xsl:template match='issue-date'>
    <issue-date>
      <year><xsl:value-of select='@year'/></year>
      <month><xsl:value-of select='@month'/></month>
      <day><xsl:value-of select='@date'/></day>
    </issue-date>
  </xsl:template>

(If the source and destination names "year", "month", "day", are known
to stay, you could even reuse the attribute names for element names.)

-- Georg



  reply	other threads:[~2004-12-06 11:18 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-02 21:04 Experiences of XML parser generators for Ada? Daniel W
2004-12-02 22:19 ` Georg Bauhaus
2004-12-03  8:57 ` Martin Krischik
2004-12-03  9:16   ` Adrien Plisson
2004-12-03 20:42     ` Daniel W
2004-12-03 23:33       ` Adrien Plisson
2004-12-04  8:05         ` Dmitry A. Kazakov
2004-12-04 11:40           ` Marius Amado Alves
2004-12-04 13:14             ` Martin Krischik
2004-12-05 16:27               ` Jeffrey Carter
2004-12-05 17:58                 ` Dmitry A. Kazakov
2004-12-04 13:59             ` Georg Bauhaus
2004-12-05  8:47               ` Martin Krischik
2004-12-06 11:18                 ` Georg Bauhaus [this message]
2004-12-06 18:12                 ` Pascal Obry
2004-12-13 20:34                   ` Florian Weimer
2004-12-05  1:50             ` David Botton
2004-12-04 14:01           ` Georg Bauhaus
2004-12-04 16:27             ` Dmitry A. Kazakov
2004-12-06  5:59         ` Daniel W
2004-12-06 14:48         ` Marc A. Criley
     [not found] <20041203110026.6F40B4C408A@lovelace.ada-france.org>
2004-12-03 23:18 ` Robert C. Leif
2004-12-07 19:41   ` Björn Persson
  -- strict thread matches above, loose matches on Subject: below --
2004-12-04 20:37 Robert C. Leif
2004-12-04 22:53 ` Adrien Plisson
2004-12-08 23:37   ` Lionel Draghi
2004-12-09 12:29     ` Georg Bauhaus
2004-12-09 21:04       ` Lionel Draghi
2004-12-09 21:09     ` Lionel Draghi
2004-12-10 22:09     ` Simon Wright
2004-12-11  0:02       ` Lionel Draghi
2004-12-11  9:03         ` Pascal Obry
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox