Hi John,
John W. Krahn wrote on 13.01.2005:
>Jan Eden wrote:
>>It also does not show up if I enclose the ternary operator in
>>brackets:
>>
>>my $server = shift || ($string =~ /(foo|bar)/ ? $1 : 'default');
>>
>>While this solves my problem, I still do not get the reason for it.
>>Could someone
Jan Eden wrote:
Hi,
Hello,
I wrote the following:
#!/usr/bin/perl -wT
use strict;
my ($server) = sitemode("test");
print $server;
sub sitemode {
my $string = "foonky";
my $server = shift || $string =~ /(foo|bar)/ ? $1 : 'default';
return $server;
}
Now this throws an error. The error do