3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = 'Total%20M%C4%81ori%2C31.5%2C33.3%2C31.8%2C33%2C36.4%2C33.2%2C33.2'; $rawstr = rawurldecode($str); var_dump( mb_detect_encoding($rawstr, ['UTF-8', 'ISO-8859-1', 'WINDOWS-1251']), mb_detect_encoding($rawstr, ['ISO-8859-1', 'WINDOWS-1251', 'UTF-8']), mb_detect_encoding($rawstr, ['WINDOWS-1251', 'UTF-8', 'ISO-8859-1']), mb_check_encoding($rawstr, 'ISO-8859-1'), mb_check_encoding($rawstr, 'UTF-8'), mb_check_encoding($rawstr, 'WINDOWS-1251'), );
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/jYDqY
function name:  (null)
number of ops:  38
compiled vars:  !0 = $str, !1 = $rawstr
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'Total%2520M%25C4%2581ori%252C31.5%252C33.3%252C31.8%252C33%252C36.4%252C33.2%252C33.2'
    4     1        INIT_FCALL                                               'rawurldecode'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $3      
          4        ASSIGN                                                   !1, $3
    6     5        INIT_FCALL                                               'var_dump'
    7     6        INIT_FCALL                                               'mb_detect_encoding'
          7        SEND_VAR                                                 !1
          8        SEND_VAL                                                 <array>
          9        DO_ICALL                                         $5      
         10        SEND_VAR                                                 $5
    8    11        INIT_FCALL                                               'mb_detect_encoding'
         12        SEND_VAR                                                 !1
         13        SEND_VAL                                                 <array>
         14        DO_ICALL                                         $6      
         15        SEND_VAR                                                 $6
    9    16        INIT_FCALL                                               'mb_detect_encoding'
         17        SEND_VAR                                                 !1
         18        SEND_VAL                                                 <array>
         19        DO_ICALL                                         $7      
         20        SEND_VAR                                                 $7
   10    21        INIT_FCALL                                               'mb_check_encoding'
         22        SEND_VAR                                                 !1
         23        SEND_VAL                                                 'ISO-8859-1'
         24        DO_ICALL                                         $8      
         25        SEND_VAR                                                 $8
   11    26        INIT_FCALL                                               'mb_check_encoding'
         27        SEND_VAR                                                 !1
         28        SEND_VAL                                                 'UTF-8'
         29        DO_ICALL                                         $9      
         30        SEND_VAR                                                 $9
   12    31        INIT_FCALL                                               'mb_check_encoding'
         32        SEND_VAR                                                 !1
         33        SEND_VAL                                                 'WINDOWS-1251'
         34        DO_ICALL                                         $10     
         35        SEND_VAR                                                 $10
    6    36        DO_ICALL                                                 
   13    37      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
142.77 ms | 1006 KiB | 17 Q