<?php
	mb_internal_encoding('utf-8');
	$text = "А роза упала на лапу Азора";
	$text = str_replace(' ','',$text);
	$text = mb_strtolower($text);
	$lenght = mb_strlen($text);
	$halfLenght = floor($lenght / 2);
	for ($i=0; $i <= $halfLenght; $i++) { 
		if (mb_substr($text, $i, $i + 1) == mb_substr($text, gmp_neg($i)) {
			echo "Полиндром!";
		}
		else{
			echo "Не Полиндром";
		}
}