El mié, 28-09-2005 a las 09:57 +1000, David Crossley escribió: > Thorsten Scherler wrote: > > Ross Gardler escribi??: > > > Thorsten Scherler wrote: > [ snip ] > > > > Either way the *real* problem that you have is that the last pipe in > > > > views is stripping the namespaces which prevent that the content of the > > > > voice markup is rendered correctly. I did not had time (and will not in > > > > the near future) to fix the strip_namespaces.xsl to let the voice ns > > > > through. Sorry. For your development comment it out and build views > > > > again. > > > > > > Why do we strip namespaces? Is it safe to let the voiceML one through? > > > > I cannot remember anymore exactly *why* but it had something to do with > > validation of the xhtml output. > > Not sure if you are talking about the Forrest core > or the plugins.
ATM the plugins, they are overriding the core (old fashion skins). > svn log main/webapp/skins/common/xslt/html/strip_namespaces.xsl > ... > FOR-541 > > Also sitemap.xmap has a "fixme" note. > http://issues.apache.org/bugzilla/show_bug.cgi?id=35348 > > The whiteboard view plugins use the same stylesheet > but there are no clues there from 'svn log'. AFAIR it was as well about forrest: and xi:. El mar, 27-09-2005 a las 15:31 +0100, Ross Gardler escribió: > If we need to strip some namespaces and not others we need a way of > configuring the strip-namespaces.xsl from a plugin otherwise plugin > developers will have to edit this XSL in core. Any sugestions how > HANAX > (or someone) can patch this namespace stripping in a more manageable > way? One workaround can be the following but it leads to the situation of plugins have to patch core xsl. <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:output method="xhtml" version="1.0" encoding="UTF-8" indent="yes"/> <xsl:template match="*[not(contains(name(),'vxml'))]"> <xsl:call-template name="removeNs"/> </xsl:template> <xsl:template match="*[contains(name(),'vxml')]"> <xsl:call-template name="keepNs"/> </xsl:template> <xsl:template name="keepNs"> <!-- do not remove element prefix (if any) --> <xsl:element name="{name()}" namespace="http://www.w3.org/2001/vxml"> <!-- process attributes --> <xsl:for-each select="@*"> <!-- do not remove attribute prefix (if any) --> <xsl:attribute name="{name()}"> <xsl:value-of select="normalize-space(.)"/> </xsl:attribute> </xsl:for-each> <xsl:apply-templates/> </xsl:element> </xsl:template> <xsl:template name="removeNs"> <!-- remove element prefix (if any) --> <xsl:element name="{local-name()}"> <!-- process attributes --> <xsl:for-each select="@*"> <!-- remove attribute prefix (if any) --> <xsl:attribute name="{local-name()}"> <xsl:value-of select="normalize-space(.)"/> </xsl:attribute> </xsl:for-each> <xsl:apply-templates/> </xsl:element> </xsl:template> </xsl:stylesheet> One could generate an alias:stylesheet (dynamic xsl) that reads in a configuration file (e.g. {theme}.fv) which defines the to excluded and included ns. <forrest:ns type="include">vxml</forrest:ns> salu2 -- thorsten "Together we stand, divided we fall!" Hey you (Pink Floyd)