I got (for example) two strings:
$a = "joao";
$b = "joão";
if ( strtoupper($a) == strtoupper($b)) {
echo $b;
}
I want it to be true even tho the accentuation. However I need it to ignore the accentuation instead of replacing because I need it to echo "joão" and not "joao".
All answers I've seen replace "ã" for "a" instead of making the comparison true. I've been reading about normalizing it, but I can't make it work either. Any ideas? Thank you.