On Jan 28, 2018 at 21:25 UTC ( #1208014=perlquestion: print w/replies, xml ) I asked a question about reading (UK) BBC 4 Radio schedules.

Monk tangent very helpfully replied giving Perl code which solved the problem. The Perl used LWP::UserAgent and is as follows
use LWP::UserAgent; my $url = 'http://www.bbc.co.uk/radio4/programmes/schedules/fm/2015/10 +/13'; my $ua = LWP::UserAgent->new(ssl_opts => {verify_hostname => 0}); my $res = $ua->get( $url ); my $html = $res->content; print $html;

I am using an implementation of Perl which is supplied by a commercial organization so that I can run their application based on Perl.
Therefore I have no detailed knowledge about how to add facilities such as LWP::UserAgent.
However, I did try but found I after I had added a Perl module yet another Perl module was required. For example, when using the Perl supplied by tangent I now get the following message:
“LWP will support https URLs if the LWP::Protocol::https module is installed.”

I did not get to a successful conclusion.

I have a new set of Perl installed so that all that I added (very likely incorrectly) is no longer there. Therefore I want to try again.

Can a monk give me the steps so that I can do whatever is necessary to get LWP::UserAgent (taking into account the message I got when trying the Perl sent by tangent) and any required Perl modules added to my version of Perl?

In reply to BBC4 Radio Schedules and LWP:UserAgent problem by merrymonk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.