3v4l.org

run code in 300+ PHP versions simultaneously
<?php /* * Author: David S. Tufts * Company: Rocketwood.LLC * www.rocketwood.com * Date: 05/25/2003 * Usage: * <img src="/barcode.php?text=testing" alt="testing" /> */ // Get pararameters that are passed in through $_GET or set to the default value $text = (isset($_GET["text"])?$_GET["text"]:"0"); $size = (isset($_GET["size"])?$_GET["size"]:"20"); $orientation = (isset($_GET["orientation"])?$_GET["orientation"]:"horizontal"); $code_type = (isset($_GET["codetype"])?$_GET["codetype"]:"code128"); $code_string = ""; // Translate the $text into barcode the correct $code_type if ( in_array(strtolower($code_type), array("code128", "code128b")) ) { $chksum = 104; // Must not change order of array elements as the checksum depends on the array's key to validate final code $code_array = array(" "=>"212222","!"=>"222122","\""=>"222221","#"=>"121223","$"=>"121322","%"=>"131222","&"=>"122213","'"=>"122312","("=>"132212",")"=>"221213","*"=>"221312","+"=>"231212",","=>"112232","-"=>"122132","."=>"122231","/"=>"113222","0"=>"123122","1"=>"123221","2"=>"223211","3"=>"221132","4"=>"221231","5"=>"213212","6"=>"223112","7"=>"312131","8"=>"311222","9"=>"321122",":"=>"321221",";"=>"312212","<"=>"322112","="=>"322211",">"=>"212123","?"=>"212321","@"=>"232121","A"=>"111323","B"=>"131123","C"=>"131321","D"=>"112313","E"=>"132113","F"=>"132311","G"=>"211313","H"=>"231113","I"=>"231311","J"=>"112133","K"=>"112331","L"=>"132131","M"=>"113123","N"=>"113321","O"=>"133121","P"=>"313121","Q"=>"211331","R"=>"231131","S"=>"213113","T"=>"213311","U"=>"213131","V"=>"311123","W"=>"311321","X"=>"331121","Y"=>"312113","Z"=>"312311","["=>"332111","\\"=>"314111","]"=>"221411","^"=>"431111","_"=>"111224","\`"=>"111422","a"=>"121124","b"=>"121421","c"=>"141122","d"=>"141221","e"=>"112214","f"=>"112412","g"=>"122114","h"=>"122411","i"=>"142112","j"=>"142211","k"=>"241211","l"=>"221114","m"=>"413111","n"=>"241112","o"=>"134111","p"=>"111242","q"=>"121142","r"=>"121241","s"=>"114212","t"=>"124112","u"=>"124211","v"=>"411212","w"=>"421112","x"=>"421211","y"=>"212141","z"=>"214121","{"=>"412121","|"=>"111143","}"=>"111341","~"=>"131141","DEL"=>"114113","FNC 3"=>"114311","FNC 2"=>"411113","SHIFT"=>"411311","CODE C"=>"113141","FNC 4"=>"114131","CODE A"=>"311141","FNC 1"=>"411131","Start A"=>"211412","Start B"=>"211214","Start C"=>"211232","Stop"=>"2331112"); $code_keys = array_keys($code_array); $code_values = array_flip($code_keys); for ( $X = 1; $X <= strlen($text); $X++ ) { $activeKey = substr( $text, ($X-1), 1); $code_string .= $code_array[$activeKey]; $chksum=($chksum + ($code_values[$activeKey] * $X)); } $code_string .= $code_array[$code_keys[($chksum - (intval($chksum / 103) * 103))]]; $code_string = "211214" . $code_string . "2331112"; } elseif ( strtolower($code_type) == "code128a" ) { $chksum = 103; $text = strtoupper($text); // Code 128A doesn't support lower case // Must not change order of array elements as the checksum depends on the array's key to validate final code $code_array = array(" "=>"212222","!"=>"222122","\""=>"222221","#"=>"121223","$"=>"121322","%"=>"131222","&"=>"122213","'"=>"122312","("=>"132212",")"=>"221213","*"=>"221312","+"=>"231212",","=>"112232","-"=>"122132","."=>"122231","/"=>"113222","0"=>"123122","1"=>"123221","2"=>"223211","3"=>"221132","4"=>"221231","5"=>"213212","6"=>"223112","7"=>"312131","8"=>"311222","9"=>"321122",":"=>"321221",";"=>"312212","<"=>"322112","="=>"322211",">"=>"212123","?"=>"212321","@"=>"232121","A"=>"111323","B"=>"131123","C"=>"131321","D"=>"112313","E"=>"132113","F"=>"132311","G"=>"211313","H"=>"231113","I"=>"231311","J"=>"112133","K"=>"112331","L"=>"132131","M"=>"113123","N"=>"113321","O"=>"133121","P"=>"313121","Q"=>"211331","R"=>"231131","S"=>"213113","T"=>"213311","U"=>"213131","V"=>"311123","W"=>"311321","X"=>"331121","Y"=>"312113","Z"=>"312311","["=>"332111","\\"=>"314111","]"=>"221411","^"=>"431111","_"=>"111224","NUL"=>"111422","SOH"=>"121124","STX"=>"121421","ETX"=>"141122","EOT"=>"141221","ENQ"=>"112214","ACK"=>"112412","BEL"=>"122114","BS"=>"122411","HT"=>"142112","LF"=>"142211","VT"=>"241211","FF"=>"221114","CR"=>"413111","SO"=>"241112","SI"=>"134111","DLE"=>"111242","DC1"=>"121142","DC2"=>"121241","DC3"=>"114212","DC4"=>"124112","NAK"=>"124211","SYN"=>"411212","ETB"=>"421112","CAN"=>"421211","EM"=>"212141","SUB"=>"214121","ESC"=>"412121","FS"=>"111143","GS"=>"111341","RS"=>"131141","US"=>"114113","FNC 3"=>"114311","FNC 2"=>"411113","SHIFT"=>"411311","CODE C"=>"113141","CODE B"=>"114131","FNC 4"=>"311141","FNC 1"=>"411131","Start A"=>"211412","Start B"=>"211214","Start C"=>"211232","Stop"=>"2331112"); $code_keys = array_keys($code_array); $code_values = array_flip($code_keys); for ( $X = 1; $X <= strlen($text); $X++ ) { $activeKey = substr( $text, ($X-1), 1); $code_string .= $code_array[$activeKey]; $chksum=($chksum + ($code_values[$activeKey] * $X)); } $code_string .= $code_array[$code_keys[($chksum - (intval($chksum / 103) * 103))]]; $code_string = "211412" . $code_string . "2331112"; } elseif ( strtolower($code_type) == "code39" ) { $code_array = array("0"=>"111221211","1"=>"211211112","2"=>"112211112","3"=>"212211111","4"=>"111221112","5"=>"211221111","6"=>"112221111","7"=>"111211212","8"=>"211211211","9"=>"112211211","A"=>"211112112","B"=>"112112112","C"=>"212112111","D"=>"111122112","E"=>"211122111","F"=>"112122111","G"=>"111112212","H"=>"211112211","I"=>"112112211","J"=>"111122211","K"=>"211111122","L"=>"112111122","M"=>"212111121","N"=>"111121122","O"=>"211121121","P"=>"112121121","Q"=>"111111222","R"=>"211111221","S"=>"112111221","T"=>"111121221","U"=>"221111112","V"=>"122111112","W"=>"222111111","X"=>"121121112","Y"=>"221121111","Z"=>"122121111","-"=>"121111212","."=>"221111211"," "=>"122111211","$"=>"121212111","/"=>"121211121","+"=>"121112121","%"=>"111212121","*"=>"121121211"); // Convert to uppercase $upper_text = strtoupper($text); for ( $X = 1; $X<=strlen($upper_text); $X++ ) { $code_string .= $code_array[substr( $upper_text, ($X-1), 1)] . "1"; } $code_string = "1211212111" . $code_string . "121121211"; } elseif ( strtolower($code_type) == "code25" ) { $code_array1 = array("1","2","3","4","5","6","7","8","9","0"); $code_array2 = array("3-1-1-1-3","1-3-1-1-3","3-3-1-1-1","1-1-3-1-3","3-1-3-1-1","1-3-3-1-1","1-1-1-3-3","3-1-1-3-1","1-3-1-3-1","1-1-3-3-1"); for ( $X = 1; $X <= strlen($text); $X++ ) { for ( $Y = 0; $Y < count($code_array1); $Y++ ) { if ( substr($text, ($X-1), 1) == $code_array1[$Y] ) $temp[$X] = $code_array2[$Y]; } } for ( $X=1; $X<=strlen($text); $X+=2 ) { if ( isset($temp[$X]) && isset($temp[($X + 1)]) ) { $temp1 = explode( "-", $temp[$X] ); $temp2 = explode( "-", $temp[($X + 1)] ); for ( $Y = 0; $Y < count($temp1); $Y++ ) $code_string .= $temp1[$Y] . $temp2[$Y]; } } $code_string = "1111" . $code_string . "311"; } elseif ( strtolower($code_type) == "codabar" ) { $code_array1 = array("1","2","3","4","5","6","7","8","9","0","-","$",":","/",".","+","A","B","C","D"); $code_array2 = array("1111221","1112112","2211111","1121121","2111121","1211112","1211211","1221111","2112111","1111122","1112211","1122111","2111212","2121112","2121211","1121212","1122121","1212112","1112122","1112221"); // Convert to uppercase $upper_text = strtoupper($text); for ( $X = 1; $X<=strlen($upper_text); $X++ ) { for ( $Y = 0; $Y<count($code_array1); $Y++ ) { if ( substr($upper_text, ($X-1), 1) == $code_array1[$Y] ) $code_string .= $code_array2[$Y] . "1"; } } $code_string = "11221211" . $code_string . "1122121"; } // Pad the edges of the barcode $code_length = 20; for ( $i=1; $i <= strlen($code_string); $i++ ) $code_length = $code_length + (integer)(substr($code_string,($i-1),1)); if ( strtolower($orientation) == "horizontal" ) { $img_width = $code_length; $img_height = $size; } else { $img_width = $size; $img_height = $code_length; } $image = imagecreate($img_width, $img_height); $black = imagecolorallocate ($image, 0, 0, 0); $white = imagecolorallocate ($image, 255, 255, 255); imagefill( $image, 0, 0, $white ); $location = 10; for ( $position = 1 ; $position <= strlen($code_string); $position++ ) { $cur_size = $location + ( substr($code_string, ($position-1), 1) ); if ( strtolower($orientation) == "horizontal" ) imagefilledrectangle( $image, $location, 0, $cur_size, $img_height, ($position % 2 == 0 ? $white : $black) ); else imagefilledrectangle( $image, 0, $location, $img_width, $cur_size, ($position % 2 == 0 ? $white : $black) ); $location = $cur_size; } // Draw barcode to the screen header ('Content-type: image/png'); imagepng($image); imagedestroy($image); ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 7
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 8
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 12, Position 2 = 16
Branch analysis from position: 12
1 jumps found. (Code = 42) Position 1 = 17
Branch analysis from position: 17
2 jumps found. (Code = 43) Position 1 = 21, Position 2 = 25
Branch analysis from position: 21
1 jumps found. (Code = 42) Position 1 = 26
Branch analysis from position: 26
2 jumps found. (Code = 43) Position 1 = 30, Position 2 = 34
Branch analysis from position: 30
1 jumps found. (Code = 42) Position 1 = 35
Branch analysis from position: 35
2 jumps found. (Code = 43) Position 1 = 42, Position 2 = 82
Branch analysis from position: 42
1 jumps found. (Code = 42) Position 1 = 68
Branch analysis from position: 68
2 jumps found. (Code = 44) Position 1 = 71, Position 2 = 54
Branch analysis from position: 71
1 jumps found. (Code = 42) Position 1 = 268
Branch analysis from position: 268
1 jumps found. (Code = 42) Position 1 = 281
Branch analysis from position: 281
2 jumps found. (Code = 44) Position 1 = 284, Position 2 = 271
Branch analysis from position: 284
2 jumps found. (Code = 43) Position 1 = 289, Position 2 = 292
Branch analysis from position: 289
1 jumps found. (Code = 42) Position 1 = 294
Branch analysis from position: 294
1 jumps found. (Code = 42) Position 1 = 366
Branch analysis from position: 366
2 jumps found. (Code = 44) Position 1 = 369, Position 2 = 322
Branch analysis from position: 369
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 322
2 jumps found. (Code = 43) Position 1 = 335, Position 2 = 350
Branch analysis from position: 335
2 jumps found. (Code = 43) Position 1 = 344, Position 2 = 346
Branch analysis from position: 344
1 jumps found. (Code = 42) Position 1 = 347
Branch analysis from position: 347
1 jumps found. (Code = 42) Position 1 = 364
Branch analysis from position: 364
2 jumps found. (Code = 44) Position 1 = 369, Position 2 = 322
Branch analysis from position: 369
Branch analysis from position: 322
Branch analysis from position: 346
1 jumps found. (Code = 42) Position 1 = 364
Branch analysis from position: 364
Branch analysis from position: 350
2 jumps found. (Code = 43) Position 1 = 359, Position 2 = 361
Branch analysis from position: 359
1 jumps found. (Code = 42) Position 1 = 362
Branch analysis from position: 362
2 jumps found. (Code = 44) Position 1 = 369, Position 2 = 322
Branch analysis from position: 369
Branch analysis from position: 322
Branch analysis from position: 361
2 jumps found. (Code = 44) Position 1 = 369, Position 2 = 322
Branch analysis from position: 369
Branch analysis from position: 322
Branch analysis from position: 292
1 jumps found. (Code = 42) Position 1 = 366
Branch analysis from position: 366
Branch analysis from position: 271
2 jumps found. (Code = 44) Position 1 = 284, Position 2 = 271
Branch analysis from position: 284
Branch analysis from position: 271
Branch analysis from position: 54
2 jumps found. (Code = 44) Position 1 = 71, Position 2 = 54
Branch analysis from position: 71
Branch analysis from position: 54
Branch analysis from position: 82
2 jumps found. (Code = 43) Position 1 = 87, Position 2 = 131
Branch analysis from position: 87
1 jumps found. (Code = 42) Position 1 = 117
Branch analysis from position: 117
2 jumps found. (Code = 44) Position 1 = 120, Position 2 = 103
Branch analysis from position: 120
1 jumps found. (Code = 42) Position 1 = 268
Branch analysis from position: 268
Branch analysis from position: 103
2 jumps found. (Code = 44) Position 1 = 120, Position 2 = 103
Branch analysis from position: 120
Branch analysis from position: 103
Branch analysis from position: 131
2 jumps found. (Code = 43) Position 1 = 136, Position 2 = 160
Branch analysis from position: 136
1 jumps found. (Code = 42) Position 1 = 153
Branch analysis from position: 153
2 jumps found. (Code = 44) Position 1 = 156, Position 2 = 143
Branch analysis from position: 156
1 jumps found. (Code = 42) Position 1 = 268
Branch analysis from position: 268
Branch analysis from position: 143
2 jumps found. (Code = 44) Position 1 = 156, Position 2 = 143
Branch analysis from position: 156
Branch analysis from position: 143
Branch analysis from position: 160
2 jumps found. (Code = 43) Position 1 = 165, Position 2 = 230
Branch analysis from position: 165
1 jumps found. (Code = 42) Position 1 = 188
Branch analysis from position: 188
2 jumps found. (Code = 44) Position 1 = 191, Position 2 = 169
Branch analysis from position: 191
1 jumps found. (Code = 42) Position 1 = 223
Branch analysis from position: 223
2 jumps found. (Code = 44) Position 1 = 226, Position 2 = 193
Branch analysis from position: 226
1 jumps found. (Code = 42) Position 1 = 268
Branch analysis from position: 268
Branch analysis from position: 193
2 jumps found. (Code = 46) Position 1 = 195, Position 2 = 198
Branch analysis from position: 195
2 jumps found. (Code = 43) Position 1 = 199, Position 2 = 222
Branch analysis from position: 199
1 jumps found. (Code = 42) Position 1 = 219
Branch analysis from position: 219
2 jumps found. (Code = 44) Position 1 = 222, Position 2 = 214
Branch analysis from position: 222
2 jumps found. (Code = 44) Position 1 = 226, Position 2 = 193
Branch analysis from position: 226
Branch analysis from position: 193
Branch analysis from position: 214
2 jumps found. (Code = 44) Position 1 = 222, Position 2 = 214
Branch analysis from position: 222
Branch analysis from position: 214
Branch analysis from position: 222
Branch analysis from position: 198
Branch analysis from position: 169
1 jumps found. (Code = 42) Position 1 = 184
Branch analysis from position: 184
2 jumps found. (Code = 44) Position 1 = 187, Position 2 = 171
Branch analysis from position: 187
2 jumps found. (Code = 44) Position 1 = 191, Position 2 = 169
Branch analysis from position: 191
Branch analysis from position: 169
Branch analysis from position: 171
2 jumps found. (Code = 43) Position 1 = 180, Position 2 = 183
Branch analysis from position: 180
2 jumps found. (Code = 44) Position 1 = 187, Position 2 = 171
Branch analysis from position: 187
Branch analysis from position: 171
Branch analysis from position: 183
Branch analysis from position: 230
2 jumps found. (Code = 43) Position 1 = 235, Position 2 = 268
Branch analysis from position: 235
1 jumps found. (Code = 42) Position 1 = 262
Branch analysis from position: 262
2 jumps found. (Code = 44) Position 1 = 265, Position 2 = 243
Branch analysis from position: 265
1 jumps found. (Code = 42) Position 1 = 281
Branch analysis from position: 281
Branch analysis from position: 243
1 jumps found. (Code = 42) Position 1 = 258
Branch analysis from position: 258
2 jumps found. (Code = 44) Position 1 = 261, Position 2 = 245
Branch analysis from position: 261
2 jumps found. (Code = 44) Position 1 = 265, Position 2 = 243
Branch analysis from position: 265
Branch analysis from position: 243
Branch analysis from position: 245
2 jumps found. (Code = 43) Position 1 = 254, Position 2 = 257
Branch analysis from position: 254
2 jumps found. (Code = 44) Position 1 = 261, Position 2 = 245
Branch analysis from position: 261
Branch analysis from position: 245
Branch analysis from position: 257
Branch analysis from position: 268
Branch analysis from position: 34
2 jumps found. (Code = 43) Position 1 = 42, Position 2 = 82
Branch analysis from position: 42
Branch analysis from position: 82
Branch analysis from position: 25
2 jumps found. (Code = 43) Position 1 = 30, Position 2 = 34
Branch analysis from position: 30
Branch analysis from position: 34
Branch analysis from position: 16
2 jumps found. (Code = 43) Position 1 = 21, Position 2 = 25
Branch analysis from position: 21
Branch analysis from position: 25
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 12, Position 2 = 16
Branch analysis from position: 12
Branch analysis from position: 16
filename:       /in/q2I43
function name:  (null)
number of ops:  379
compiled vars:  !0 = $text, !1 = $size, !2 = $orientation, !3 = $code_type, !4 = $code_string, !5 = $chksum, !6 = $code_array, !7 = $code_keys, !8 = $code_values, !9 = $X, !10 = $activeKey, !11 = $upper_text, !12 = $code_array1, !13 = $code_array2, !14 = $Y, !15 = $temp, !16 = $temp1, !17 = $temp2, !18 = $code_length, !19 = $i, !20 = $img_width, !21 = $img_height, !22 = $image, !23 = $black, !24 = $white, !25 = $location, !26 = $position, !27 = $cur_size
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   FETCH_IS                                         ~28     '_GET'
          1        ISSET_ISEMPTY_DIM_OBJ                         0          ~28, 'text'
          2      > JMPZ                                                     ~29, ->7
          3    >   FETCH_R                      global              ~30     '_GET'
          4        FETCH_DIM_R                                      ~31     ~30, 'text'
          5        QM_ASSIGN                                        ~32     ~31
          6      > JMP                                                      ->8
          7    >   QM_ASSIGN                                        ~32     '0'
          8    >   ASSIGN                                                   !0, ~32
   14     9        FETCH_IS                                         ~34     '_GET'
         10        ISSET_ISEMPTY_DIM_OBJ                         0          ~34, 'size'
         11      > JMPZ                                                     ~35, ->16
         12    >   FETCH_R                      global              ~36     '_GET'
         13        FETCH_DIM_R                                      ~37     ~36, 'size'
         14        QM_ASSIGN                                        ~38     ~37
         15      > JMP                                                      ->17
         16    >   QM_ASSIGN                                        ~38     '20'
         17    >   ASSIGN                                                   !1, ~38
   15    18        FETCH_IS                                         ~40     '_GET'
         19        ISSET_ISEMPTY_DIM_OBJ                         0          ~40, 'orientation'
         20      > JMPZ                                                     ~41, ->25
         21    >   FETCH_R                      global              ~42     '_GET'
         22        FETCH_DIM_R                                      ~43     ~42, 'orientation'
         23        QM_ASSIGN                                        ~44     ~43
         24      > JMP                                                      ->26
         25    >   QM_ASSIGN                                        ~44     'horizontal'
         26    >   ASSIGN                                                   !2, ~44
   16    27        FETCH_IS                                         ~46     '_GET'
         28        ISSET_ISEMPTY_DIM_OBJ                         0          ~46, 'codetype'
         29      > JMPZ                                                     ~47, ->34
         30    >   FETCH_R                      global              ~48     '_GET'
         31        FETCH_DIM_R                                      ~49     ~48, 'codetype'
         32        QM_ASSIGN                                        ~50     ~49
         33      > JMP                                                      ->35
         34    >   QM_ASSIGN                                        ~50     'code128'
         35    >   ASSIGN                                                   !3, ~50
   17    36        ASSIGN                                                   !4, ''
   20    37        INIT_FCALL                                               'strtolower'
         38        SEND_VAR                                                 !3
         39        DO_ICALL                                         $53     
         40        IN_ARRAY                                                 $53, <array>
         41      > JMPZ                                                     ~54, ->82
   21    42    >   ASSIGN                                                   !5, 104
   23    43        ASSIGN                                                   !6, <array>
   24    44        INIT_FCALL                                               'array_keys'
         45        SEND_VAR                                                 !6
         46        DO_ICALL                                         $57     
         47        ASSIGN                                                   !7, $57
   25    48        INIT_FCALL                                               'array_flip'
         49        SEND_VAR                                                 !7
         50        DO_ICALL                                         $59     
         51        ASSIGN                                                   !8, $59
   26    52        ASSIGN                                                   !9, 1
         53      > JMP                                                      ->68
   27    54    >   INIT_FCALL                                               'substr'
         55        SEND_VAR                                                 !0
         56        SUB                                              ~62     !9, 1
         57        SEND_VAL                                                 ~62
         58        SEND_VAL                                                 1
         59        DO_ICALL                                         $63     
         60        ASSIGN                                                   !10, $63
   28    61        FETCH_DIM_R                                      ~65     !6, !10
         62        ASSIGN_OP                                     8          !4, ~65
   29    63        FETCH_DIM_R                                      ~67     !8, !10
         64        MUL                                              ~68     !9, ~67
         65        ADD                                              ~69     !5, ~68
         66        ASSIGN                                                   !5, ~69
   26    67        PRE_INC                                                  !9
         68    >   STRLEN                                           ~72     !0
         69        IS_SMALLER_OR_EQUAL                                      !9, ~72
         70      > JMPNZ                                                    ~73, ->54
   31    71    >   DIV                                              ~74     !5, 103
         72        CAST                                          4  ~75     ~74
         73        MUL                                              ~76     ~75, 103
         74        SUB                                              ~77     !5, ~76
         75        FETCH_DIM_R                                      ~78     !7, ~77
         76        FETCH_DIM_R                                      ~79     !6, ~78
         77        ASSIGN_OP                                     8          !4, ~79
   33    78        CONCAT                                           ~81     '211214', !4
         79        CONCAT                                           ~82     ~81, '2331112'
         80        ASSIGN                                                   !4, ~82
         81      > JMP                                                      ->268
   34    82    >   INIT_FCALL                                               'strtolower'
         83        SEND_VAR                                                 !3
         84        DO_ICALL                                         $84     
         85        IS_EQUAL                                                 $84, 'code128a'
         86      > JMPZ                                                     ~85, ->131
   35    87    >   ASSIGN                                                   !5, 103
   36    88        INIT_FCALL                                               'strtoupper'
         89        SEND_VAR                                                 !0
         90        DO_ICALL                                         $87     
         91        ASSIGN                                                   !0, $87
   38    92        ASSIGN                                                   !6, <array>
   39    93        INIT_FCALL                                               'array_keys'
         94        SEND_VAR                                                 !6
         95        DO_ICALL                                         $90     
         96        ASSIGN                                                   !7, $90
   40    97        INIT_FCALL                                               'array_flip'
         98        SEND_VAR                                                 !7
         99        DO_ICALL                                         $92     
        100        ASSIGN                                                   !8, $92
   41   101        ASSIGN                                                   !9, 1
        102      > JMP                                                      ->117
   42   103    >   INIT_FCALL                                               'substr'
        104        SEND_VAR                                                 !0
        105        SUB                                              ~95     !9, 1
        106        SEND_VAL                                                 ~95
        107        SEND_VAL                                                 1
        108        DO_ICALL                                         $96     
        109        ASSIGN                                                   !10, $96
   43   110        FETCH_DIM_R                                      ~98     !6, !10
        111        ASSIGN_OP                                     8          !4, ~98
   44   112        FETCH_DIM_R                                      ~100    !8, !10
        113        MUL                                              ~101    !9, ~100
        114        ADD                                              ~102    !5, ~101
        115        ASSIGN                                                   !5, ~102
   41   116        PRE_INC                                                  !9
        117    >   STRLEN                                           ~105    !0
        118        IS_SMALLER_OR_EQUAL                                      !9, ~105
        119      > JMPNZ                                                    ~106, ->103
   46   120    >   DIV                                              ~107    !5, 103
        121        CAST                                          4  ~108    ~107
        122        MUL                                              ~109    ~108, 103
        123        SUB                                              ~110    !5, ~109
        124        FETCH_DIM_R                                      ~111    !7, ~110
        125        FETCH_DIM_R                                      ~112    !6, ~111
        126        ASSIGN_OP                                     8          !4, ~112
   48   127        CONCAT                                           ~114    '211412', !4
        128        CONCAT                                           ~115    ~114, '2331112'
        129        ASSIGN                                                   !4, ~115
        130      > JMP                                                      ->268
   49   131    >   INIT_FCALL                                               'strtolower'
        132        SEND_VAR                                                 !3
        133        DO_ICALL                                         $117    
        134        IS_EQUAL                                                 $117, 'code39'
        135      > JMPZ                                                     ~118, ->160
   50   136    >   ASSIGN                                                   !6, <array>
   53   137        INIT_FCALL                                               'strtoupper'
        138        SEND_VAR                                                 !0
        139        DO_ICALL                                         $120    
        140        ASSIGN                                                   !11, $120
   55   141        ASSIGN                                                   !9, 1
        142      > JMP                                                      ->153
   56   143    >   INIT_FCALL                                               'substr'
        144        SEND_VAR                                                 !11
        145        SUB                                              ~123    !9, 1
        146        SEND_VAL                                                 ~123
        147        SEND_VAL                                                 1
        148        DO_ICALL                                         $124    
        149        FETCH_DIM_R                                      ~125    !6, $124
        150        CONCAT                                           ~126    ~125, '1'
        151        ASSIGN_OP                                     8          !4, ~126
   55   152        PRE_INC                                                  !9
        153    >   STRLEN                                           ~129    !11
        154        IS_SMALLER_OR_EQUAL                                      !9, ~129
        155      > JMPNZ                                                    ~130, ->143
   59   156    >   CONCAT                                           ~131    '1211212111', !4
        157        CONCAT                                           ~132    ~131, '121121211'
        158        ASSIGN                                                   !4, ~132
        159      > JMP                                                      ->268
   60   160    >   INIT_FCALL                                               'strtolower'
        161        SEND_VAR                                                 !3
        162        DO_ICALL                                         $134    
        163        IS_EQUAL                                                 $134, 'code25'
        164      > JMPZ                                                     ~135, ->230
   61   165    >   ASSIGN                                                   !12, <array>
   62   166        ASSIGN                                                   !13, <array>
   64   167        ASSIGN                                                   !9, 1
        168      > JMP                                                      ->188
   65   169    >   ASSIGN                                                   !14, 0
        170      > JMP                                                      ->184
   66   171    >   INIT_FCALL                                               'substr'
        172        SEND_VAR                                                 !0
        173        SUB                                              ~140    !9, 1
        174        SEND_VAL                                                 ~140
        175        SEND_VAL                                                 1
        176        DO_ICALL                                         $141    
        177        FETCH_DIM_R                                      ~142    !12, !14
        178        IS_EQUAL                                                 $141, ~142
        179      > JMPZ                                                     ~143, ->183
   67   180    >   FETCH_DIM_R                                      ~145    !13, !14
        181        ASSIGN_DIM                                               !15, !9
        182        OP_DATA                                                  ~145
   65   183    >   PRE_INC                                                  !14
        184    >   COUNT                                            ~147    !12
        185        IS_SMALLER                                               !14, ~147
        186      > JMPNZ                                                    ~148, ->171
   64   187    >   PRE_INC                                                  !9
        188    >   STRLEN                                           ~150    !0
        189        IS_SMALLER_OR_EQUAL                                      !9, ~150
        190      > JMPNZ                                                    ~151, ->169
   71   191    >   ASSIGN                                                   !9, 1
        192      > JMP                                                      ->223
   72   193    >   ISSET_ISEMPTY_DIM_OBJ                         0  ~153    !15, !9
        194      > JMPZ_EX                                          ~153    ~153, ->198
        195    >   ADD                                              ~154    !9, 1
        196        ISSET_ISEMPTY_DIM_OBJ                         0  ~155    !15, ~154
        197        BOOL                                             ~153    ~155
        198    > > JMPZ                                                     ~153, ->222
   73   199    >   INIT_FCALL                                               'explode'
        200        SEND_VAL                                                 '-'
        201        FETCH_DIM_R                                      ~156    !15, !9
        202        SEND_VAL                                                 ~156
        203        DO_ICALL                                         $157    
        204        ASSIGN                                                   !16, $157
   74   205        INIT_FCALL                                               'explode'
        206        SEND_VAL                                                 '-'
        207        ADD                                              ~159    !9, 1
        208        FETCH_DIM_R                                      ~160    !15, ~159
        209        SEND_VAL                                                 ~160
        210        DO_ICALL                                         $161    
        211        ASSIGN                                                   !17, $161
   75   212        ASSIGN                                                   !14, 0
        213      > JMP                                                      ->219
   76   214    >   FETCH_DIM_R                                      ~164    !16, !14
        215        FETCH_DIM_R                                      ~165    !17, !14
        216        CONCAT                                           ~166    ~164, ~165
        217        ASSIGN_OP                                     8          !4, ~166
   75   218        PRE_INC                                                  !14
        219    >   COUNT                                            ~169    !16
        220        IS_SMALLER                                               !14, ~169
        221      > JMPNZ                                                    ~170, ->214
   71   222    >   ASSIGN_OP                                     1          !9, 2
        223    >   STRLEN                                           ~172    !0
        224        IS_SMALLER_OR_EQUAL                                      !9, ~172
        225      > JMPNZ                                                    ~173, ->193
   80   226    >   CONCAT                                           ~174    '1111', !4
        227        CONCAT                                           ~175    ~174, '311'
        228        ASSIGN                                                   !4, ~175
        229      > JMP                                                      ->268
   81   230    >   INIT_FCALL                                               'strtolower'
        231        SEND_VAR                                                 !3
        232        DO_ICALL                                         $177    
        233        IS_EQUAL                                                 $177, 'codabar'
        234      > JMPZ                                                     ~178, ->268
   82   235    >   ASSIGN                                                   !12, <array>
   83   236        ASSIGN                                                   !13, <array>
   86   237        INIT_FCALL                                               'strtoupper'
        238        SEND_VAR                                                 !0
        239        DO_ICALL                                         $181    
        240        ASSIGN                                                   !11, $181
   88   241        ASSIGN                                                   !9, 1
        242      > JMP                                                      ->262
   89   243    >   ASSIGN                                                   !14, 0
        244      > JMP                                                      ->258
   90   245    >   INIT_FCALL                                               'substr'
        246        SEND_VAR                                                 !11
        247        SUB                                              ~185    !9, 1
        248        SEND_VAL                                                 ~185
        249        SEND_VAL                                                 1
        250        DO_ICALL                                         $186    
        251        FETCH_DIM_R                                      ~187    !12, !14
        252        IS_EQUAL                                                 $186, ~187
        253      > JMPZ                                                     ~188, ->257
   91   254    >   FETCH_DIM_R                                      ~189    !13, !14
        255        CONCAT                                           ~190    ~189, '1'
        256        ASSIGN_OP                                     8          !4, ~190
   89   257    >   PRE_INC                                                  !14
        258    >   COUNT                                            ~193    !12
        259        IS_SMALLER                                               !14, ~193
        260      > JMPNZ                                                    ~194, ->245
   88   261    >   PRE_INC                                                  !9
        262    >   STRLEN                                           ~196    !11
        263        IS_SMALLER_OR_EQUAL                                      !9, ~196
        264      > JMPNZ                                                    ~197, ->243
   94   265    >   CONCAT                                           ~198    '11221211', !4
        266        CONCAT                                           ~199    ~198, '1122121'
        267        ASSIGN                                                   !4, ~199
   98   268    >   ASSIGN                                                   !18, 20
   99   269        ASSIGN                                                   !19, 1
        270      > JMP                                                      ->281
  100   271    >   INIT_FCALL                                               'substr'
        272        SEND_VAR                                                 !4
        273        SUB                                              ~203    !19, 1
        274        SEND_VAL                                                 ~203
        275        SEND_VAL                                                 1
        276        DO_ICALL                                         $204    
        277        CAST                                          4  ~205    $204
        278        ADD                                              ~206    !18, ~205
        279        ASSIGN                                                   !18, ~206
   99   280        PRE_INC                                                  !19
        281    >   STRLEN                                           ~209    !4
        282        IS_SMALLER_OR_EQUAL                                      !19, ~209
        283      > JMPNZ                                                    ~210, ->271
  102   284    >   INIT_FCALL                                               'strtolower'
        285        SEND_VAR                                                 !2
        286        DO_ICALL                                         $211    
        287        IS_EQUAL             

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
271.5 ms | 1428 KiB | 26 Q