in reply to Comparing lower to upper case
If you only need things to be the same case for the comparison, then you can use uc or lc to force your strings to be upper or lower.
if ( uc($str) eq uc($something) ) { # ... }
Alternately, and if you need care about the original case, you can reassign $str to an upper- or lowercased version of itself before you do anything else.
$str = uc($str); # force uppercase
--k.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Comparing lower to upper case
by bobothesmart (Initiate) on Jun 11, 2002 at 18:57 UTC | |
by joshua (Pilgrim) on Jun 11, 2002 at 19:50 UTC |