Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"

Re^2: XML::Twig::flush() and html/xml entities

by mandarin (Hermit)
on Oct 05, 2006 at 13:55 UTC ( #576536=note: print w/replies, xml ) Need Help??

in reply to Re: XML::Twig::flush() and html/xml entities
in thread XML::Twig::flush() and html/xml entities

I changed the code in line 28 to both
my $elt_txt = $elt->xml_text;
my $elt_txt = $elt->xml_string;
(and left anything else alone)
but neither did work out, I still get the convertet ampersand.
Do I have to play around with the output_filter, too?
I must admit that I didn't quite understand how that works.


update: Even text in tags never touched by the section
function is undergoing changes.

Replies are listed 'Best First'.
Re^3: XML::Twig::flush() and html/xml entities
by mirod (Canon) on Oct 05, 2006 at 15:17 UTC

    Ooops! That will teach me to test the code before answering. Is there any reason why you use the keep_encoding option? Without it it works fine, with it, indeed the & is not escaped in the output. You should only use this option if you are dealing with non-utf8 encodings, and want all the processing to be done in the original encoding, which doesn't seem to be your case.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://576536]
[Spenser]: It's a stripped down version on a NAS device.
[Spenser]: It's frustrating
[Spenser]: Perl 5.10.0
[Spenser]: It uses opkg to install software
[choroba]: 5.10.1 would be much better
[shmem]: there are so many ways thinkable to fix that situation, some feasible and some not, that I'm unable to give good advice.
[Spenser]: I installed 5.22 with opkg. I can use it with cpan. I'm actually trying to install perl-DBD-mysql, but couldn't with it. So I went back to the factory version, 5.10.
[Spenser]: So, nevermind about CPAN. I give up on the downgraded angle. I'm back to fighting to install DBD.
[shmem]: please open a SoPW. At what point is the perl-DBD-mysql installation failing?
[shmem]: do you have the mysqlclient libs on that device, for instance?

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (8)
As of 2018-03-17 12:42 GMT
Find Nodes?
    Voting Booth?
    When I think of a mole I think of:

    Results (224 votes). Check out past polls.