Subject: Re: [xsl] xsl:transform From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx> Date: Fri, 22 Jun 2001 16:44:13 +0100 |
>Hi, > >I would like to transform from one xml into another one >using a 'lookup' xml file....
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
Hoping it works, Wendell
>Here is the original xml file : > ><?xml version="1.0"?> ><file1> > <col1>01</col1> > <col2>Hello</col2> > <col3>world</col3> > <col4>GTP</col4> > <col5>02 Jul 1999 09:45:05:706</col5> ></file1> > >using this 'lookup' xml file : ><?xml version="1.0"?> ><xref> > <file1> > <abbr>col1</abbr><name>label1</name> > <abbr>col2</abbr><name>label2</name> > <abbr>col3</abbr><name>label3</name> > <abbr>col4</abbr><name>label4</name> > <abbr>col5</abbr><name>label5</name> > </file1> > <file2> > <abbr>col1</abbr><name>header1</name> > <abbr>col2</abbr><name>header2</name> > </file2> ></xref> > > >the xml result is : ><?xml version="1.0"?> ><file1> > <label1>01</label1> > <label2>Hello</label2> > <label3>world</label3> > <label4>GTP</label4> > <label5>02 Jul 1999 09:45:05:706</label5> ></file1> > >If the original xml file : > ><?xml version="1.0"?> ><file2> > <col1>12345</col1> > <col2>Welcome</col2> ></file2> > >using the same 'lookup' xml file, the result is : ><?xml version="1.0"?> ><file2> > <header1>12345</header1> > <header2>Welcome</header2> ></file2> > >Any idea how to ? >Thanks for any suggestions.
====================================================================== 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 |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] xsl:transform, B. Tommie Usdin | Thread | [xsl] Putting parameter into XPATH , MacEwan, James (Info |
Re: [xsl] Document() Problem:, David Carlisle | Date | Re: [xsl] Convert to a Nodelist, David Carlisle |
Month |