You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xalan.apache.org by Santiago Pericas-Geertsen <Sa...@Sun.COM> on 2004/02/13 15:03:34 UTC

Re: xml transformation is removing tags instead of transforming them - maybe text encoding problem?

On Fri, 2004-02-13 at 06:55, Henning Sprang wrote:
> 
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <SubscriptionRequest Sender="motivmgr"
>     TimeStamp="2004-02-13T10:47:01.314+01:00" xmlns="vdv454eng">
>     <AUSSubscription SubscriptionID="1"
> ValidUntilTimeStamp="2004-02-14T10:47:01.314+01:00">
>         <LineID></LineID>
>         <Hysteresises>5</Hysteresises>
>         <PreviewTime>60</PreviewTime>
>     </AUSSubscription>
> </SubscriptionRequest>
> 

 Notice the redefinition of the default namespace in the element
SubscriptionRequest (xmlns="vdv454eng"), which was not present in the
document you showed earlier. That is causing pattern matching to fail in
your stylesheet. To match on an element like that you'd need a template
like this:

<xsl:template match="someprefix:SubscriptionRequest">

 where 'someprefix' is bound to "vdv454eng".

 Hope this helps.

-- Santiago