3v4l.org

run code in 300+ PHP versions simultaneously
<?php $result = "°Freenew° \x90ɮ\xc2\xe4dfg"; //$result = trim($result,"\xc2"/*"\xa0"*/); //echo preg_replace('#[\x00-\x1F\x7F-\x9F]#', '', $result); //reject overly long 2 byte sequences, as well as characters above U+10000 and replace with ? echo preg_replace('/[\x00-\x08\x10\x0B\x0C\x0E-\x19\x7F]'. '|[\x00-\x7F][\x80-\xBF]+'. '|([\xC0\xC1]|[\xF0-\xFF])[\x80-\xBF]*'. '|[\xC2-\xDF]((?![\x80-\xBF])|[\x80-\xBF]{2,})'. '|[\xE0-\xEF](([\x80-\xBF](?![\x80-\xBF]))|(?![\x80-\xBF]{2})|[\x80-\xBF]{3,})/S', '', $result ); /* //reject overly long 3 byte sequences and UTF-16 surrogates and replace with ? $some_string = preg_replace('/\xE0[\x80-\x9F][\x80-\xBF]'. '|\xED[\xA0-\xBF][\x80-\xBF]/S','?', $some_string ); */
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Igb1i
function name:  (null)
number of ops:  8
compiled vars:  !0 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%C2%B0Freenew%C2%B0+%90%C9%AE%C2%E4dfg'
   10     1        INIT_FCALL                                               'preg_replace'
   14     2        SEND_VAL                                                 '%2F%5B%5Cx00-%5Cx08%5Cx10%5Cx0B%5Cx0C%5Cx0E-%5Cx19%5Cx7F%5D%7C%5B%5Cx00-%5Cx7F%5D%5B%5Cx80-%5CxBF%5D%2B%7C%28%5B%5CxC0%5CxC1%5D%7C%5B%5CxF0-%5CxFF%5D%29%5B%5Cx80-%5CxBF%5D%2A%7C%5B%5CxC2-%5CxDF%5D%28%28%3F%21%5B%5Cx80-%5CxBF%5D%29%7C%5B%5Cx80-%5CxBF%5D%7B2%2C%7D%29%7C%5B%5CxE0-%5CxEF%5D%28%28%5B%5Cx80-%5CxBF%5D%28%3F%21%5B%5Cx80-%5CxBF%5D%29%29%7C%28%3F%21%5B%5Cx80-%5CxBF%5D%7B2%7D%29%7C%5B%5Cx80-%5CxBF%5D%7B3%2C%7D%29%2FS'
   15     3        SEND_VAL                                                 ''
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $2      
          6        ECHO                                                     $2
   22     7      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
162.65 ms | 1394 KiB | 15 Q