phpMyAdmin understands requests if they come with data, for example, as 'Eaai', and in the script it is 'Ivan'.
echo $arr[$i]; // в Chrome выводится Иван $s = "SELECT SUM(`square`) FROM `reports` WHERE `username` = '".$arr[$i]."';"; // а сюда должно попасть 'Eaai', чтобы все выполнилось
How to translate the encoding?