You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Torsten Curdt <tc...@dff.st> on 2001/10/05 16:12:33 UTC

empty tag name - a bug?

Can a transformation really make a tag loose it's name?!
Or is this a bug?!

I realized the following strange behaviour:

<myns:tag>
  <myns:tag>something</myns:tag>
  text
  <othertag>bla</othertag>
</myns:tag>

After a transformation (and this fragment is copied
by the copying default template) I get

<myns:tag>
  <myns:tag>something</myns:tag>
  text
  < xmlns="http://www.dff.st/myns">bla</>
</myns:tag>

from the XML Serializer. NO TAG NAME??

I will investigate further and have a look into
the events itself with the beautiful log transform :)

But this should be possible at all, should it?!
--
Torsten

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: empty tag name - a bug?

Posted by Stefano Mazzocchi <st...@apache.org>.
Torsten Curdt wrote:
> 
> Can a transformation really make a tag loose it's name?!
> Or is this a bug?!
> 
> I realized the following strange behaviour:
> 
> <myns:tag>
>   <myns:tag>something</myns:tag>
>   text
>   <othertag>bla</othertag>
> </myns:tag>
> 
> After a transformation (and this fragment is copied
> by the copying default template) I get
> 
> <myns:tag>
>   <myns:tag>something</myns:tag>
>   text
>   < xmlns="http://www.dff.st/myns">bla</>
> </myns:tag>
> 
> from the XML Serializer. NO TAG NAME??
> 
> I will investigate further and have a look into
> the events itself with the beautiful log transform :)
> 
> But this should be possible at all, should it?!

Ouch, no. Of course, not: the result is not well-formed XML.

Can you give us more info on how to recreate this? Thanks.

-- 
Stefano Mazzocchi      One must still have chaos in oneself to be
                          able to give birth to a dancing star.
<st...@apache.org>                             Friedrich Nietzsche
--------------------------------------------------------------------



---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: empty tag name - a bug?

Posted by "Piroumian, Konstantin" <KP...@flagship.ru>.
You can get also empty attributes like this <tag =""> if you use SAX to
produce your XML. No validation is performed (at least in Xerces SAXParser)
at the creation stage. (setAttribute("", "", "", ...) - is enabled by the
parser).

Anyway, it's not a valid XML.

> Can a transformation really make a tag loose it's name?!
> Or is this a bug?!
>
> I realized the following strange behaviour:
>
> <myns:tag>
>   <myns:tag>something</myns:tag>
>   text
>   <othertag>bla</othertag>
> </myns:tag>
>
> After a transformation (and this fragment is copied
> by the copying default template) I get
>
> <myns:tag>
>   <myns:tag>something</myns:tag>
>   text
>   < xmlns="http://www.dff.st/myns">bla</>
> </myns:tag>
>
> from the XML Serializer. NO TAG NAME??
>
> I will investigate further and have a look into
> the events itself with the beautiful log transform :)
>
> But this should be possible at all, should it?!
> --
> Torsten
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org