3v4l.org

run code in 300+ PHP versions simultaneously
<?php $text="ála"; for($d=0;$d<strlen($text);$d++) { echo $text[$d] . "<br>"; } $char = 'á'; $char = 'a'; $hex = dechex(mb_ord($char)); var_dump($hex);
Output for 7.4.0 - 7.4.33, 8.0.1 - 8.0.30, 8.1.0 - 8.1.27, 8.2.0 - 8.2.17, 8.3.0 - 8.3.4
�<br>�<br>l<br>a<br>string(2) "61"

preferences:
117.13 ms | 402 KiB | 117 Q