[Home]  [List]  [News]  [Docs]  [FAQ]  [Downloads]  [Resources]  [About]
Search :
/Home /List

list4xt : Mailing list for the XT users community.

[list4xt] Re: Entities in output file. why?

Subject: [list4xt] Re: Entities in output file. why?
From: Carlberg, Anders (Anders.Carlberg@infologigruppen.se)
Date: 04/10/2000 - 23:03


Hi!.

Im using xslt to generate a new xslt file that i will apply on another xml
file.
(does this make any sence at all? =) ).

example. i uses xsl:element to create new xsl:stylesheet in the output.

Here are my xslt file:
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:template match="xml">
        <xsl:element name="xsl:stylesheet">
                <xsl:attribute name="version">1.0</xsl:attribute>

                <xsl:element name="xsl:template">
                        <xsl:attribute name="match">xml</xsl:attribute>

                        <xsl:apply-templates select="textbox"/>

                </xsl:element>
        </xsl:element>
</xsl:template>

<xsl:template match="textbox">
        <xsl:element name="input">
                <xsl:element name="name"><xsl:value-of
select="name/text()"/></xsl:element>
                <xsl:element name="value">
                        <xsl:element name="xsl:value-of">
                                <xsl:attribute name="select"><xsl:value-of
select="value/text()" />/text()</xsl:attribute>
                        </xsl:element>
                </xsl:element>
        </xsl:element>
</xsl:template>
</xsl:stylesheet>

the xml file:
<xml>
        <textbox>
                <name>mytextbox</name>
                <value>/xml/name</value>
        </textbox>
</xml>

The result of this should be something like this:
<xsl:stylesheet version="1.0">
  <xsl:template match="xml">
    <input>
      <name>mytextbox</name>
      <value>
        <xsl:value-of select="/xml/name/text()"></xsl:value-of>
      </value>
  </xsl:template>
</xsl:stylesheet>

Thanks..

/Anders

-----Original Message-----
From: Eric van der Vlist [mailto:vdv@dyomedea.com]
Sent: den 4 oktober 2000 15:45
To: list4xt@4xt.org
Subject: [list4xt] Re: Entities in output file. why?

Anders,

I don't understand what you want to achieve.

Can you tell us more ?

(for instance, do you want to generate a conferment XML file ?)

Eric

"Carlberg, Anders" wrote:
>
> Hi!
>
> I'm using the FileDestination to get a output into a file,
> but i dont understand why i get entities in the output.
>
> like this:
> <?xml version="1.0" encoding="utf-8"?>
> &lt;xml&gt; &lt;textbox&gt; &lt;name&gt;mytextbox&lt;/name&gt;
> &lt;value&gt;Anders&lt;/value&gt; &lt;/textbox&gt; &lt;/xml&gt;
>
> I have tried to set the encoding and contentType but it dont changes
> anything.
> Where do i set this, so i get:
> <xml><textbox>...... output?
>
> Help me understand this.
>
> Thanks in advance
> /Anders
>
> Anders Carlberg
> Infologigruppen Norr AB
> Furunäsvägen 105
> S-941 52 Piteĺ Sweden
>
> Tel. +46 91193428
> Fax. +46 91193425
> Mob. +46 703169511
> Mob. Fax. +46 703833817
>
> --
> Mailing list for the XT users community. (http://newcitybankchicago.com)
> (mailto:list4xt-request@4xt.org?Subject=unsubscribe to unsubscribe)

-- 
------------------------------------------------------------------------
Eric van der Vlist       Dyomedea                    http://antelopehighlandschamber.com
http://creditcardprocessingadvice.com -           http://webzinearticles.com              http://creditcardprocessingtravelindustry.com
------------------------------------------------------------------------

-- Mailing list for the XT users community. (http://bardcreditunion.com) (mailto:list4xt-request@4xt.org?Subject=unsubscribe to unsubscribe)

-- Mailing list for the XT users community. (http://gpmerchantcapital.com) (mailto:list4xt-request@4xt.org?Subject=unsubscribe to unsubscribe)



Archive générée par hypermail 2b28 le 06/11/2001 - 11:46 CET

webmaster@4xt.org


A site designed by Dyomedea