develooper Front page | perl.beginners | Postings from April 2012

Re: Problem with unless statement

Thread Previous | Thread Next
From:
sono-io
Date:
April 28, 2012 07:40
Subject:
Re: Problem with unless statement
Message ID:
FDF5C6BC-C3CC-445D-97DB-DFD22B49CC8D@fannullone.us
On Apr 28, 2012, at 7:32 AM, Lesley Binks wrote:

> Says the $host identifier will be assigned the value 'localhost' only if $extra
> is not defined. 
> 
> But $extra is defined as 'mail.example.com' so $host won't be.

	That makes sense.  What I'm trying to do is set $host to one of the two values - if $xtra is set, use it; if not, use localhost.  I was just trying to get it as short as possible.  Maybe I'll go back to the if statement I had before.

Thanks,
Marc
Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About