Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: uninitialized value in concatenation

by ikegami (Patriarch)
on Nov 16, 2010 at 19:33 UTC ( [id://871812]=note: print w/replies, xml ) Need Help??


in reply to uninitialized value in concatenation

You cut off a relevant part of the error message: "or string". You have a string literal (<<EOF .. EOF) which interpolates an undefined variable. $email_400, $main_domain, $ENV{REDIRECT_URL} or $ENV{HTTP_REFERER} evaluates to undef. A more recent version of Perl would actually identify which in the error message.

Replies are listed 'Best First'.
Re^2: uninitialized value in concatenation
by Galceran (Initiate) on Nov 16, 2010 at 20:11 UTC

    Possibly relates to the opening lines of the script</>

    #!/usr/bin/perl -w use strict; my ($email_400, $email_500, $unfriendly_error, $redirect_to); my $main_domain=getpwuid($<); my @sendmail_path=(qw(/usr/sbin/sendmail -i -odb), "-fdcm\@nineone.org +"); ## Uncomment the below two lines to get emailed regarding the respecti +ve ## errors. $email_400="dcm\@$main_domain"; $email_500="dcm\@$main_domain";

    should I give the whole script - 110 lines?

      should I give the whole script - 110 lines?

      Why? The warning has already been explained. (I was going to say your question has already been answered, but you have yet to actually ask a question.)

      I presume you want to know which variable isn't defined and why, but that's simple debugging. You can use defined to determine which variable isn't defined. To find out why it isn't defined, find out where the variable is getting set (if it's getting set at all) and find out when the initialiser might be undefined.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (7)
As of 2024-04-16 06:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found