isync has asked for the wisdom of the Perl Monks concerning the following question:
Using content() works but gives (at least in console) garbled data. Doing decode("utf8", $response->content) looks like doubly decoding.#!/usr/bin/perl use LWP::UserAgent; use utf8; my $agent = LWP::UserAgent->new(); my $response = $agent->get('http://www.ku6.com/show/34D6sgY4X6w3YegR.h +tml'); print $response->decoded_content ."\n";
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Chinese site and decoded_content() trouble
by graff (Chancellor) on Jun 09, 2007 at 04:06 UTC | |
by varian (Chaplain) on Jun 09, 2007 at 08:57 UTC | |
by isync (Hermit) on Jun 11, 2007 at 08:54 UTC | |
Re: Chinese site and decoded_content() trouble
by valdez (Monsignor) on Jun 09, 2007 at 17:54 UTC | |
by isync (Hermit) on Jun 11, 2007 at 08:50 UTC |