Re: error printing page using LWP::Simple
- From: Tim Greer <tim@xxxxxxxxxxxxx>
- Date: Fri, 06 Feb 2009 09:19:01 -0800
Gunnar Hjalmarsson wrote:
Tim Greer wrote:
Larry Gates wrote:
On Thu, 05 Feb 2009 20:50:36 -0800, Tim Greer wrote:
You'll need to use $t = (get $url or
"value"); instead -- that does work after trying.
Works? Well, sort of. It assigns "value" to $t if $url does not
contain a true value, but if $url contains a true value,
That was in reply to someone that suggested get $url or "error", which
wouldn't work unless you put parenthesis. That's why I said "If you
use that, you could do this..."
my $t = get ($url) or "error"; would make more sense.
it does not
tell whether the get() function succeeds or why it fails.
Right.
You can also use:
my $t = get $url || "There was a problem";
Same objection.
True.
--
Tim Greer, CEO/Founder/CTO, BurlyHost.com, Inc.
Shared Hosting, Reseller Hosting, Dedicated & Semi-Dedicated servers
and Custom Hosting. 24/7 support, 30 day guarantee, secure servers.
Industry's most experienced staff! -- Web Hosting With Muscle!
.
- References:
- error printing page using LWP::Simple
- From: Larry Gates
- Re: error printing page using LWP::Simple
- From: Tim Greer
- Re: error printing page using LWP::Simple
- From: Larry Gates
- Re: error printing page using LWP::Simple
- From: Chris Mattern
- Re: error printing page using LWP::Simple
- From: Larry Gates
- Re: error printing page using LWP::Simple
- From: Tim Greer
- Re: error printing page using LWP::Simple
- From: Larry Gates
- Re: error printing page using LWP::Simple
- From: Tim Greer
- Re: error printing page using LWP::Simple
- From: Larry Gates
- Re: error printing page using LWP::Simple
- From: Tim Greer
- Re: error printing page using LWP::Simple
- From: Gunnar Hjalmarsson
- error printing page using LWP::Simple
- Prev by Date: Re: error printing page using LWP::Simple
- Next by Date: Re: error printing page using LWP::Simple
- Previous by thread: Re: error printing page using LWP::Simple
- Next by thread: Re: error printing page using LWP::Simple
- Index(es):
Relevant Pages
|
Loading