in reply to how to put XML string in table cell

What is the real HTML output of your script?

Also, if you want to print the XML that is contained in $x, then you maybe want to learn about how HTML encodes <>.

I suggest HTML::Entities:

print encode_entities( $x );

Replies are listed 'Best First'.
Re^2: how to put XML string in table cell
by bimleshsharma (Beadle) on Jan 22, 2014 at 10:27 UTC

    i analysed the html code and found that things are coming right..

    <table><tr><td>1</td><td>"Soap Msg Comp"</td><td>49214792</td><td><?xm +l version="1.0" encoding="utf-8" ?> <Soap-ENV:Envelope version="1.1"> <Soap-ENV:Body> <CheckTrade> <tradeId>4921492</tradeId> </CheckTrade> </Soap-ENV:Body> </Soap-ENV:Envelope></td></tr></table>

      No, they are not coming right. <Soap-ENV: is not a valid HTML tag.

        ok, i found the way to do that. Just we need to encode the string as below ...

        use HTML::Entities; my $x= encode_entities( $x );

        and use below in td section

        <table><tr><td>test</td><td>$x</td></tr></table>