Why can't Perl find the match??

by David Moninger <David.Moninger(at)IslandTime.com>

 Date:  Sat, 06 May 2000 10:05:53 -0400
 To:  hwg-languages(at)hwg.org
  todo: View Thread, Original
I'm going slowly nuts trying to figure out why a "eq" compare of two email 
address strings is failing ... can someone please help me find my probably 
stupid error?

=========
I accepted an email address from a form

	$v_email = $in{'00_v_email'};

I open a file
read the data to an array
and Close the File (Die & flock removed for brevity)

	open (ML,"$MasterListPath") || die ;
	@database_array = <ML>;
	close(ML);

I chomp to remove garbage

	foreach $lines(@database_array)
	{
	chomp($lines);
	chomp($v_email);
			
I set all to lower case

	$lines =~ tr/A-Z/a-z/;
	$v_email =~ tr/A-Z/a-z/;

I print out both values and they LOOK the same

	print "$lines $v_email<BR>";

I do a compare
			if ($lines eq $v_email)
			{       				

But Don't get a match!

	print "Address match found<BR>";


Whats up??

Thanks for any help anyone can provide!

david

HWG: hwg-languages mailing list archives, maintained by Webmasters @ IWA