xsl-list
[Top] [All Lists]

[xsl] Problem in XSL transformation

2006-09-06 22:16:33
Hi All,

We have the following requirements.

1. We want to retain the HTML tags which are part of the XML output from a HTTP 
server. The output is in form of raw XML and we don't want to loose the 
formatting (HTML tags) while transforming. 
2. We want to replace double quote to a special character and line breaks to 
<br> tag to be used for further processing. 

The problem is that we are not able to retain the formatting when we retain the 
HTML tags. 

We are using template for replacing double quotes and line breaks. The code is 
as follows.

<xsl:output method="html" indent="no"/>

<xsl:template match="p">
        <p> 
        <xsl:call-template name="transformXMLString">
                <xsl:with-param name="StringToTransform" select="."/>
        </xsl:call-template>    
        </p>      
   </xsl:template>

Here transformXMLString is the name of the template which replaces line breaks 
and double quotes. This is simple recursive function for character replacement. 
We are getting some unwanted characters after transformation. In csv file, this 
is visible as small boxes.

Any clues?


Thanks & Regards,
Ambika Prasad Das
 


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--