use LWP::Simple;
use utf8;
binmode(STDIN, ":encoding(gbk)");
binmode(STDOUT, ":encoding(gbk)");
binmode(STDERR, ":encoding(gbk)");
use Encode;
my $url = 'https://cloud.tencent.com/developer/article/1977955?areaSource=104001.20&traceId=_XRHkDkgvZ-7VAiqdgtAk';
my $content = get($url);
if (defined $content) {
# 对网页内容进行处理,例如打印到屏幕上
print $content;
my @lines = split /\n/, $content;
foreach my $line (@lines) {
print "$line\n";
}
} else {
print "无法获取页面内容\n";
}