Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > apice xsl

Reply
Thread Tools

apice xsl

 
 
fedorola
Guest
Posts: n/a
 
      03-18-2005
Salve a tutti
ho un problema con gli apici in xsl.
Ho uno stylesheet in xsl che al click di un link chiama una funzione
javascript outInfo per lanciare un popup informativo

<xsl:element name="input">
<xsl:attribute name="name">codfis</xsl:attribute>
<xsl:attribute name="type">hidden</xsl:attribute>
<a href="#"
onclick="outInfo('{@codfis}','{@denominazione}','{ @indirizzo}');return
false">
<xsl:value-of select="@codfis"/></a>
</xsl:element>

Il problema è dato dai campi che passo come parametri poiche'
contengono il carattere ' che viene visto da javascript come fine
stringa e impazzisce.
Più o meno so come convertire il carattere ma non riesco a far capire
a xsl che il carattere da convertite è proprio '. ho provato con '
con &quot; tra apici tra virgolette ma niente...
 
Reply With Quote
 
 
 
 
Joe Fawcett
Guest
Posts: n/a
 
      03-18-2005
"fedorola" <> wrote in message
news: m...
> Salve a tutti
> ho un problema con gli apici in xsl.
> Ho uno stylesheet in xsl che al click di un link chiama una funzione
> javascript outInfo per lanciare un popup informativo
>
> <xsl:element name="input">
> <xsl:attribute name="name">codfis</xsl:attribute>
> <xsl:attribute name="type">hidden</xsl:attribute>
> <a href="#"
> onclick="outInfo('{@codfis}','{@denominazione}','{ @indirizzo}');return
> false">
> <xsl:value-of select="@codfis"/></a>
> </xsl:element>
>
> Il problema è dato dai campi che passo come parametri poiche'
> contengono il carattere ' che viene visto da javascript come fine
> stringa e impazzisce.
> Più o meno so come convertire il carattere ma non riesco a far capire
> a xsl che il carattere da convertite è proprio '. ho provato con '
> con &quot; tra apici tra virgolette ma niente...


L'entità per l'apostrofo è &-a-p-o-s-;. Non penso che questo aiuti benchè possa
comprendere male il problema. Certamente questo è un problema di Javascript non
un XSLT uno?


--

Joe (MVP - XML)


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
XSL Question tp xsl:for-each and xsl:variable schaf@2wire.ch XML 1 05-27-2005 09:25 PM
tomcal/xsl - problems with xsl:include Klaus Friese Java 0 11-22-2004 10:17 AM
XSL-1000: (Fatal Error) Error while parsing XSL file (org.apache.xerces.parsers.AbstractSAXParser$AttributesProxy) Kevin Flood Java 1 09-13-2004 02:28 PM
XSL-1000: (Fatal Error) Error while parsing XSL file (org.apache.xerces.parsers.AbstractSAXParser$AttributesProxy) Kevin Flood Java 0 09-08-2004 02:11 PM
use xsl:element to output an "<xsl:template match=...> ? Ray Tayek XML 3 11-30-2003 10:14 AM



Advertisments