3v4l.org

run code in 300+ PHP versions simultaneously
<?php //$input = trim("Premium serviço Personal - 1 m�"); $input = 'Premium serviço Personal - 1 mês'; var_dump( utf8_encode(utf8_decode($input)) ); var_dump( utf8_encode($input) ); var_dump( utf8_decode($input) ); var_dump( mb_convert_encoding($input, 'utf-8', 'utf-8') ); var_dump( filter_var($input, FILTER_SANITIZE_ENCODED, FILTER_FLAG_STRIP_LOW) ); var_dump(preg_replace('#[\x00-\x08\x0B-\x1F\x7F-\x9F]+#u', '', $input)) ; var_dump(htmlspecialchars_decode(htmlspecialchars($input, ENT_NOQUOTES | ENT_IGNORE, 'UTF-8'), ENT_NOQUOTES));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ENJPR
function name:  (null)
number of ops:  59
compiled vars:  !0 = $input
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, 'Premium+servi%C3%A7o+Personal+-+1+m%C3%AAs'
    5     1        INIT_FCALL                                               'var_dump'
          2        INIT_FCALL                                               'utf8_encode'
          3        INIT_FCALL                                               'utf8_decode'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $2      
          6        SEND_VAR                                                 $2
          7        DO_ICALL                                         $3      
          8        SEND_VAR                                                 $3
          9        DO_ICALL                                                 
    6    10        INIT_FCALL                                               'var_dump'
         11        INIT_FCALL                                               'utf8_encode'
         12        SEND_VAR                                                 !0
         13        DO_ICALL                                         $5      
         14        SEND_VAR                                                 $5
         15        DO_ICALL                                                 
    7    16        INIT_FCALL                                               'var_dump'
         17        INIT_FCALL                                               'utf8_decode'
         18        SEND_VAR                                                 !0
         19        DO_ICALL                                         $7      
         20        SEND_VAR                                                 $7
         21        DO_ICALL                                                 
    8    22        INIT_FCALL                                               'var_dump'
         23        INIT_FCALL                                               'mb_convert_encoding'
         24        SEND_VAR                                                 !0
         25        SEND_VAL                                                 'utf-8'
         26        SEND_VAL                                                 'utf-8'
         27        DO_ICALL                                         $9      
         28        SEND_VAR                                                 $9
         29        DO_ICALL                                                 
    9    30        INIT_FCALL                                               'var_dump'
         31        INIT_FCALL                                               'filter_var'
         32        SEND_VAR                                                 !0
         33        SEND_VAL                                                 514
         34        SEND_VAL                                                 4
         35        DO_ICALL                                         $11     
         36        SEND_VAR                                                 $11
         37        DO_ICALL                                                 
   10    38        INIT_FCALL                                               'var_dump'
         39        INIT_FCALL                                               'preg_replace'
         40        SEND_VAL                                                 '%23%5B%5Cx00-%5Cx08%5Cx0B-%5Cx1F%5Cx7F-%5Cx9F%5D%2B%23u'
         41        SEND_VAL                                                 ''
         42        SEND_VAR                                                 !0
         43        DO_ICALL                                         $13     
         44        SEND_VAR                                                 $13
         45        DO_ICALL                                                 
   11    46        INIT_FCALL                                               'var_dump'
         47        INIT_FCALL                                               'htmlspecialchars_decode'
         48        INIT_FCALL                                               'htmlspecialchars'
         49        SEND_VAR                                                 !0
         50        SEND_VAL                                                 4
         51        SEND_VAL                                                 'UTF-8'
         52        DO_ICALL                                         $15     
         53        SEND_VAR                                                 $15
         54        SEND_VAL                                                 0
         55        DO_ICALL                                         $16     
         56        SEND_VAR                                                 $16
         57        DO_ICALL                                                 
         58      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
167.28 ms | 1400 KiB | 29 Q