One way of doing this:
chop ($username);
if ($username eq "") {
...
}
This will at least ensure that a carriage return
is not included in the scalar
PJD
- Original Message -
From: "Matthew Harrison" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday,
This may help..a very basic file I/O
open(INFILE,"yourfile");
open (OUTFILE,"outfilename");
while ($line=) {
chomp $line;
next if ($line eq "");
print OUTFILE $line;
}
You could also slurp it into an array, but
- Original Message -
From: "Kim, Kiseok" <[EMAIL PROTECTED]>
To: <[EM
You might want to try using the input line separator system variable
"$/". By default it is "\n", but you can set it to whatever you like
e.g.
$/ = " "; #This makes the newline character a whitespace
so then
$testValue1 = "a b";
might be what you want to accomplish, I'm not sure,
Hope this hel
Try this:
for ($i=0; $i<@inlocation; $i++) {
print ("Error location is required\n") if ( $inlocation[$i] !~
/\w+/);
}
- Original Message -
From: "Scot Robnett" <[EMAIL PROTECTED]>
To: "Teresa Raymond" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Wednesday, May 01, 2002 8:03 PM