Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris

Re: LWP::Simple is it get decoded or not ?

by rpnoble419 (Pilgrim)
on Aug 10, 2012 at 13:28 UTC ( #986741=note: print w/ replies, xml ) Need Help??

in reply to LWP::Simple is it get decoded or not ?

Uncode support changed in Perl 5.10 from the way it was handled in 5.8.8. Look at for more information

Comment on Re: LWP::Simple is it get decoded or not ?
Replies are listed 'Best First'.
Re^2: LWP::Simple is it get decoded or not ?
by remiah (Hermit) on Aug 10, 2012 at 22:52 UTC
    thanks for reply rpnoble419.

    I will read through perluniintro, perlunicode anyway. This time, really.

    i became a little bit nervous for decoding, encoding way of each modules now.

    dbd::sqlite gives me decoded character if i set sqlite_unicode to 1, but they seems automatically encode characters to bytes when i put characters to database regardless of sqlite_unicode switch. it gives me no warnings when i put decoded characters to databases when i don't use sqlite_unicode. i thought dbd::ado gave me warning... wasn't it ?

    when i pass decoded characters to template toolkit, i pass binmode switch to proccess function. For "decoding" template file it self, I am using Template::Provider::Encoding.

    And now LWP::Simple... It seems I am stumbling all unicode stones.

Re^2: LWP::Simple is it get decoded or not ?
by remiah (Hermit) on Aug 11, 2012 at 04:07 UTC

    It was version difference of LWP::Simple to get decoded character or not decoded bytes.

    5.810 of LWP::Simple doesn't use decoded_content() but it uses content() method. On the other hand 5.835 uses decoded_content() method, so it returns decoded character.

    I decided to use useragent and decoded_content explicitly, to work with each enviornment. Below is test script with LWP::Simple 5.810

    thanks a lot.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://986741]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (6)
As of 2015-11-28 17:05 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (743 votes), past polls