Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: Using LWP::Simple with a callback (progress indicator)

by barrd (Canon)
on Sep 16, 2003 at 11:32 UTC ( [id://291785]=note: print w/replies, xml ) Need Help??


in reply to Using LWP::Simple with a callback (progress indicator)

Update: After bart's reply I have edited my original post

Hi bart,
Cool, but a couple of points:

  1. No use strict;... tsk tsk ;)
  2. opening a filehandle without checking i.e.
    open HTML, ">monastery_gates.html" or die "Can't open HTML: $!";

    -- bart added use Fatal 'open';
  3. While we're on the subject you haven't closed it either
    close HTML or die "Can't close HTML: $!";
I think these are important enough to warrant pointing them out.

No offence meant.

~barrd

Replies are listed 'Best First'.
Re: Re: Using LWP::Simple with a callback (progress indicator)
by bart (Canon) on Sep 16, 2003 at 11:36 UTC
    Heh, odd... I do have the error checking in the version here at home. I'll edit that. (Done — in a slightly unusual manner :))

    As for the rest... *waves hand* this is just a snippet. You have to know when this stuff matters.

      Okey cokey bart,
      Sorry, didn't realise it was intended as a snippet. Please accept my apologies but I was just trying to point out some common errors for any 'newbies' who may have read it. I am not of course implying that you are a 'newbie' :).

      Peace, ~barrd

      Update:

      (Done — in a slightly unusual manner :))
      Indeed, I've never seen it done "that" way before ;)

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (4)
As of 2024-04-23 07:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found