3v4l.org

run code in 300+ PHP versions simultaneously
<?php iconv_set_encoding('internal_encoding', 'UTF-8'); iconv_set_encoding('input_encoding', 'UTF-8'); iconv_set_encoding('output_encoding', 'UTF-8'); $headers = <<< HEADERS X-Header-One: H4sIAAAAAAAAA+NgFlsCAAA= X-Header-Two: XtLePq6GTMn8G68F0 HEADERS; echo "Wrong decoding:\n"; var_dump(iconv_mime_decode_headers($headers, ICONV_MIME_DECODE_CONTINUE_ON_ERROR)); echo "Correct decoding:\n"; var_dump(iconv_mime_decode_headers($headers, ICONV_MIME_DECODE_STRICT));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/QcCSR
function name:  (null)
number of ops:  30
compiled vars:  !0 = $headers
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   3     0  E >   INIT_FCALL                                               'iconv_set_encoding'
         1        SEND_VAL                                                 'internal_encoding'
         2        SEND_VAL                                                 'UTF-8'
         3        DO_ICALL                                                 
   4     4        INIT_FCALL                                               'iconv_set_encoding'
         5        SEND_VAL                                                 'input_encoding'
         6        SEND_VAL                                                 'UTF-8'
         7        DO_ICALL                                                 
   5     8        INIT_FCALL                                               'iconv_set_encoding'
         9        SEND_VAL                                                 'output_encoding'
        10        SEND_VAL                                                 'UTF-8'
        11        DO_ICALL                                                 
   8    12        ASSIGN                                                   !0, 'X-Header-One%3A+H4sIAAAAAAAAA%2BNgFlsCAAA%3D%0AX-Header-Two%3A+XtLePq6GTMn8G68F0'
  12    13        ECHO                                                     'Wrong+decoding%3A%0A'
  13    14        INIT_FCALL                                               'var_dump'
        15        INIT_FCALL                                               'iconv_mime_decode_headers'
        16        SEND_VAR                                                 !0
        17        SEND_VAL                                                 2
        18        DO_ICALL                                         $5      
        19        SEND_VAR                                                 $5
        20        DO_ICALL                                                 
  15    21        ECHO                                                     'Correct+decoding%3A%0A'
  16    22        INIT_FCALL                                               'var_dump'
        23        INIT_FCALL                                               'iconv_mime_decode_headers'
        24        SEND_VAR                                                 !0
        25        SEND_VAL                                                 1
        26        DO_ICALL                                         $7      
        27        SEND_VAR                                                 $7
        28        DO_ICALL                                                 
        29      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
14.15 ms | 411 KiB | 7 Q