[Solved] ñ to Ñ string php


You will need to play with encoding.

$content="Nuñez";

mb_internal_encoding('UTF-8');
if(!mb_check_encoding($content, 'UTF-8')
OR !($content === mb_convert_encoding(mb_convert_encoding($content, 'UTF-32', 'UTF-8' ), 'UTF-8', 'UTF-32'))) {

$content = mb_convert_encoding($content, 'UTF-8'); 
}

// NUÑEZ
echo mb_convert_case($content, MB_CASE_UPPER, "UTF-8"); 

via PHP: mb_strtoupper not working

solved ñ to Ñ string php