Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^2: Why am I getting "premature end of script header"?

by ikegami (Patriarch)
on Nov 28, 2006 at 18:57 UTC ( #586553=note: print w/replies, xml ) Need Help??


in reply to Re: Why am I getting "premature end of script header"?
in thread Why am I getting "premature end of script header"?

That doesn't work. See Re^3: Why am I getting "premature end of script header"? - eval { use } for an explanation. What one could do is replace the aformentioned

BEGIN { eval(" use LWP::UserAgent (); use HTTP::Request::Common; "); if ($@) { ... } } ...

with

BEGIN { eval { require LWP::UserAgent; require HTTP::Request::Common; import HTTP::Request::Common; }; if ($@) { ... } } ...

The difference between the two is just a question of style.

Replies are listed 'Best First'.
A reply falls below the community's threshold of quality. You may see it by logging in.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (3)
As of 2022-08-08 04:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?