T
Tjerk Wolterink
Hello all,
I've a problem:
i've an xsl file that has a template that contains
the following:
<script type="text/javascript">
<![CDATA[
a long javascript with < > characters, like:
for(var i=0;i<xmlDataFunctions.length;i++) {
}
]]>>
</script>
Ok when this is transformed i get the following:
<script type="text/javascript">
a long javascript with < > characters, like:
for(var i=0;i<xmlDataFunctions.length;i++) {
}
</script>
But i dont want this, because javascript does not now < and >
So i used:
<script type="text/javascript"><xsl:text disable-output-escaping="yes"><![CDATA[
a long javascript with < > characters, like:
for(var i=0;i<xmlDataFunctions.length;i++) {
}
]]></xsl:text></script>
Ok now i get:
<script type="text/javascript">
a long javascript with < > characters, like:
for(var i=0;i<xmlDataFunctions.length;i++) {
}
</script>
But because it is all part of an web-application i want to
get valid xhtml. This is not valid.So what i want is this as output:
<script type="text/javascript">
<![CDATA[
a long javascript with < > characters, like:
for(var i=0;i<xmlDataFunctions.length;i++) {
}
]]>
</script>
How do i do that with xslt??
I've a problem:
i've an xsl file that has a template that contains
the following:
<script type="text/javascript">
<![CDATA[
a long javascript with < > characters, like:
for(var i=0;i<xmlDataFunctions.length;i++) {
}
]]>>
</script>
Ok when this is transformed i get the following:
<script type="text/javascript">
a long javascript with < > characters, like:
for(var i=0;i<xmlDataFunctions.length;i++) {
}
</script>
But i dont want this, because javascript does not now < and >
So i used:
<script type="text/javascript"><xsl:text disable-output-escaping="yes"><![CDATA[
a long javascript with < > characters, like:
for(var i=0;i<xmlDataFunctions.length;i++) {
}
]]></xsl:text></script>
Ok now i get:
<script type="text/javascript">
a long javascript with < > characters, like:
for(var i=0;i<xmlDataFunctions.length;i++) {
}
</script>
But because it is all part of an web-application i want to
get valid xhtml. This is not valid.So what i want is this as output:
<script type="text/javascript">
<![CDATA[
a long javascript with < > characters, like:
for(var i=0;i<xmlDataFunctions.length;i++) {
}
]]>
</script>
How do i do that with xslt??