Heiko Wundram
2013-07-24 09:20:59 UTC
Hey!
I'm currently facing the problem (which I hadn't noticed before) that it
seems impossible with built-in means to filter attributes that are applied
to a child with select("@*") due to the fact that generic XPath-expressions
with local-name() on attributes don't work. This means that transforming
something like:
<a image="test" href="#">Test</a>
to
<a href="#"><span class="glyphicons test"><i /></span>Test</a>
is currently impossible using a match template. I'm using the specific test
case with glyphicons, because it'd be rather fortunate to be able to define
respective elements as attributes of the "a" and not have to resort to a
structure as
<a href="#"><image>test</image>Test</a>
which can be transformed, but makes code so much more verbose and confuses
the internationalization (as there's a contained tag)... Is there any
working patchset for Genshi which implements this? I've seen
http://genshi.edgewall.org/ticket/81 which contains a patchset, but that
doesn't work for the "simple" cases that I threw at it.
Thanks for any hint!
--- Heiko Wundram.
I'm currently facing the problem (which I hadn't noticed before) that it
seems impossible with built-in means to filter attributes that are applied
to a child with select("@*") due to the fact that generic XPath-expressions
with local-name() on attributes don't work. This means that transforming
something like:
<a image="test" href="#">Test</a>
to
<a href="#"><span class="glyphicons test"><i /></span>Test</a>
is currently impossible using a match template. I'm using the specific test
case with glyphicons, because it'd be rather fortunate to be able to define
respective elements as attributes of the "a" and not have to resort to a
structure as
<a href="#"><image>test</image>Test</a>
which can be transformed, but makes code so much more verbose and confuses
the internationalization (as there's a contained tag)... Is there any
working patchset for Genshi which implements this? I've seen
http://genshi.edgewall.org/ticket/81 which contains a patchset, but that
doesn't work for the "simple" cases that I threw at it.
Thanks for any hint!
--- Heiko Wundram.
--
You received this message because you are subscribed to the Google Groups "Genshi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to genshi+***@googlegroups.com.
To post to this group, send email to ***@googlegroups.com.
Visit this group at http://groups.google.com/group/genshi.
For more options, visit https://groups.google.com/groups/opt_out.
You received this message because you are subscribed to the Google Groups "Genshi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to genshi+***@googlegroups.com.
To post to this group, send email to ***@googlegroups.com.
Visit this group at http://groups.google.com/group/genshi.
For more options, visit https://groups.google.com/groups/opt_out.