3v4l.org

run code in 300+ PHP versions simultaneously
<?php /* reset */ $tracking_code = $capcha1 = $capcha2 = $data = ''; /* Site 1 */ /* Sometimes this site gives an error so check before you run your request via normal website, the error comes up at $x("//span[@id='span1']/text()") via firebug console as the russian "База данных временно недоступна, повторите запрос позже." (database not accessible try again later) */ $tracking_code = 'CP021325078TR'; $url1 = 'http://www.russianpost.ru/tracking20/'; $capcha_url1 = 'http://www.russianpost.ru/tracking20/Code/Code.png.ashx'; //$postfields1 = '?BarCode='.$tracking_code.'&Code='.$capcha1; // check I haven't checked this in detail /* Site 2 */ $url2 = 'http://www1.ptt.gov.tr/tr/interaktif/kayitliposta-yd_yeniweb.php'; $capcha_url2 = 'http://www1.ptt.gov.tr/tr/interaktif/CaptchaSecurityImages.php?width=100&height=40&characters=5'; //$postfields2 = '?barkod='.$tracking_code.'&security_code'.$capcha2; // check I haven't checked this in detail. function fix_keys($array = null) { foreach ($array as $k => $val) { if(is_array($val)) { $array[$k] = fix_keys($val); } } return array_values($array); } function translit_Turkish($inputText) { $search = array('ç', 'Ç', 'ğ', 'Ğ', 'ı', 'i','I', 'İ', 'ö', 'Ö', 'ş', 'Ş', 'ü', 'Ü', 'Ãœ', 'Ä°', 'ö'); $replace = array('c', 'C', 'g', 'G', 'i', 'i','I', 'I', 'o', 'O', 's', 'S', 'u', 'U', 'U', 'I', 'o'); return str_replace($search, $replace, $inputText); } function clean_gunk($input) { $search = array( '&nbsp;',); return str_replace($search, '', $input); } function to_array($DomList) { $array = array(); foreach($DomList as $list) { $array[] = $list->nodeValue; } return $array; } function preview($results = null) { echo '<pre>'; print_r($results); echo '<br/>Node Values <br/>'; foreach($results as $result){ echo trim($result->nodeValue).'<br/>'; $array[] = $result; } echo '<br/><br/>'; if (isset($array)) { @print_r($array); // php error : not implemented yet. } } function get_capcha($url = null, $file) { $cookie = dirname(__FILE__).'/receita.txt.'; $fn = fopen($file,"w+"); $options = array ( CURLOPT_RETURNTRANSFER => TRUE, // dont need webpage data CURLOPT_BINARYTRANSFER => TRUE, // yes binary. CURLOPT_SSL_VERIFYPEER => FALSE, CURLOPT_SSL_VERIFYHOST => FALSE, CURLOPT_FOLLOWLOCATION => TRUE, CURLOPT_AUTOREFERER => TRUE, CURLOPT_NOPROGRESS => TRUE, CURLOPT_ENCODING => 'gzip', CURLOPT_CONNECTTIMEOUT => 240, CURLOPT_TIMEOUT => 240, CURLOPT_USERAGENT => 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6', // Setting the useragent CURLOPT_URL => $url, // URL that produces an image captcha. CURLOPT_COOKIE => 1, CURLOPT_COOKIESESSION => TRUE, CURLOPT_COOKIEFILE => $cookie, // do this more under the spell of the captcha CURLOPT_COOKIEJAR => $cookie, // this over the top make magic .. ah already said that; CURLOPT_FILE => $fn, ); $ch = curl_init(); curl_setopt_array($ch,$options); curl_exec($ch); curl_close($ch); fclose($fn); } if($_SERVER['REQUEST_METHOD'] == "POST") { //$capcha1 = trim($_POST['capchacode1']); //$capcha2 = $_POST['capchacode2']; $cnpj = $_POST ['cnpj']; $cnpj2 = $_POST ['cnpj2']; /* cURL rel stuff start */ $tracking_code = 'CP021325078TR'; $url = "http://www1.ptt.gov.tr/tr/interaktif/sonuc-yd.php"; $post_fields = 'barkod='.$tracking_code.'&security_code='.$cnpj; $agent = 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6'; $reffer = "http://www1.ptt.gov.tr/tr/interaktif/kayitliposta-yd_yeniweb.php"; $cookie = dirname(__FILE__).'/receita.txt.'; $header = array('Referer: xxx', 'Origin: '.$url, 'Content-Type: application/x-www-form-urlencoded', 'Connection: keep-alive', 'Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3', 'Cache-Control: max-age=0', 'Except:'); $options = array ( CURLOPT_URL => $url, CURLOPT_POST => 1, CURLOPT_POSTFIELDS => $post_fields, CURLOPT_USERAGENT => $agent, CURLOPT_REFERER => $reffer, CURLOPT_COOKIEFILE => $cookie, CURLOPT_COOKIEJAR => $cookie, CURLOPT_FOLLOWLOCATION => 1, CURLOPT_RETURNTRANSFER => 1, CURLOPT_HEADER => 0, ); $ch = curl_init(); curl_setopt_array($ch, $options); $response2 = curl_exec($ch); curl_close($ch); //$response1 <- should be from url1 //$response2 <- should be from url2 /*$url2 = "http://www.russianpost.ru/tracking20/CheckSubscription.js.aspx"; $post_fields2 = 'Id='.$tracking_code.'&Code='.$cnpj2.'&Language=Russian'; $reffer2 = "http://www.russianpost.ru/tracking20/"; // http://www.russianpost.ru/tracking20/CheckSubscription.js.aspx?Id=CP021325078TR&Code=84084&Language=Russian //http://www.russianpost.ru/tracking20/PostalOrderEventsForMail.js.aspx?Id=CP021325078TR&Code=84084&Language=Russian $options2 = array ( CURLOPT_URL => $url2, CURLOPT_POST => 1, CURLOPT_POSTFIELDS => $post_fields2, CURLOPT_USERAGENT => $agent, CURLOPT_REFERER => $reffer2, CURLOPT_COOKIEFILE => $cookie, CURLOPT_COOKIEJAR => $cookie, CURLOPT_FOLLOWLOCATION => 1, CURLOPT_RETURNTRANSFER => 1, CURLOPT_HEADER => 0, ); $ch2 = curl_init(); curl_setopt_array($ch2, $options2); $response1 = curl_exec($ch2); curl_close($ch2); /*S cURL rel stuff end */ print_r($response2); // for site 1 // query to get text data from page : http://www.russianpost.ru/tracking20/ // "//table[@id='tbl1']//tbody//tr//td/text()" /*$dom = new DOMDocument(); @$dom->loadHTML($response1); $xpath = new DOMXPATH($dom); $data1 = to_array($xpath->query("//table[@id='tbl1']//tbody//tr//td/text()")); // checked query via browser ok */ // for site 2 // query to get text data from page : http://www1.ptt.gov.tr/tr/interaktif/sonuc-yd.php // "(//table)[3]//tbody//tr//td/text()|(//table)[9]//tbody//tr//td/text()" //$remove = '<html xmlns="http://www.w3.org/1999/xhtml">'; //$response2 = str_replace($remove, '', $response2); $wr = fopen('temp.txt','w+'); fwrite($wr, $response2); fclose($wr); //$response2 = str_replace('&nbsp;', '', $response2); $response2 = iconv('iso-8859-9','utf-8', $response2); $response2 = clean_gunk(translit_Turkish($response2)); $dom = new DOMDocument(); @$dom->loadHTML($response2); $xpath = new DOMXPATH($dom); //preview($xpath2); //top part $data = to_array($xpath->query("(//table[3]//tr//text())")); //checked via browser ok. $data = fix_keys(array_filter($data, create_function('$a','return trim($a)!=="";'))); for($i=0; $i<count($data); $i=$i+5){ $row[] = trim(str_replace(' ','',$data[$i])).','.trim($data[$i+1]).','.trim($data[$i+2]).','.trim($data[$i+3]).','.trim($data[$i+4]); } var_dump($row); //bottom part $data2 = to_array($xpath->query("(//table[9]//tr//text())")); //checked via browser ok. $data2 = fix_keys(array_filter($data2, create_function('$a','return trim($a)!=="";'))); unset($data2[0]); unset($data2[1]); unset($data2[2]); $data2 = fix_keys($data2); for($i=0; $i<count($data2); $i=$i+3){ $row2[] = trim(str_replace(' ','',$data2[$i])).','.trim($data2[$i+1]).','.trim($data2[$i+2]); } var_dump($row2); //preview($data); // display $data1 and $data2 shouldn't be null if the curl returned the correct result pages. echo '<pre>'; //var_dump($data1); //var_dump($data1); //var_dump($data); } else { get_capcha ($capcha_url2, "capcha.jpg"); //get_capcha ($capcha_url1, "capcha2.jpg"); // And create the form that + image shows the input field CNPJ echo "<img src = 'capcha.jpg' />". "<img src = 'capcha2.jpg' />". '<form action = "'.htmlentities($_SERVER['PHP_SELF']).'" method = "POST"> captcha <input name = "cnpj"> <input name = "cnpj2"> <input type = "submit"> </ form> '; } ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 247
Branch analysis from position: 13
1 jumps found. (Code = 42) Position 1 = 178
Branch analysis from position: 178
2 jumps found. (Code = 44) Position 1 = 181, Position 2 = 137
Branch analysis from position: 181
1 jumps found. (Code = 42) Position 1 = 239
Branch analysis from position: 239
2 jumps found. (Code = 44) Position 1 = 242, Position 2 = 212
Branch analysis from position: 242
1 jumps found. (Code = 42) Position 1 = 259
Branch analysis from position: 259
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 212
2 jumps found. (Code = 44) Position 1 = 242, Position 2 = 212
Branch analysis from position: 242
Branch analysis from position: 212
Branch analysis from position: 137
2 jumps found. (Code = 44) Position 1 = 181, Position 2 = 137
Branch analysis from position: 181
Branch analysis from position: 137
Branch analysis from position: 247
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uUksV
function name:  (null)
number of ops:  260
compiled vars:  !0 = $tracking_code, !1 = $capcha1, !2 = $capcha2, !3 = $data, !4 = $url1, !5 = $capcha_url1, !6 = $url2, !7 = $capcha_url2, !8 = $cnpj, !9 = $cnpj2, !10 = $url, !11 = $post_fields, !12 = $agent, !13 = $reffer, !14 = $cookie, !15 = $header, !16 = $options, !17 = $ch, !18 = $response2, !19 = $wr, !20 = $dom, !21 = $xpath, !22 = $i, !23 = $row, !24 = $data2, !25 = $row2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                           ~26     !3, ''
          1        ASSIGN                                           ~27     !2, ~26
          2        ASSIGN                                           ~28     !1, ~27
          3        ASSIGN                                                   !0, ~28
   10     4        ASSIGN                                                   !0, 'CP021325078TR'
   12     5        ASSIGN                                                   !4, 'http%3A%2F%2Fwww.russianpost.ru%2Ftracking20%2F'
   13     6        ASSIGN                                                   !5, 'http%3A%2F%2Fwww.russianpost.ru%2Ftracking20%2FCode%2FCode.png.ashx'
   17     7        ASSIGN                                                   !6, 'http%3A%2F%2Fwww1.ptt.gov.tr%2Ftr%2Finteraktif%2Fkayitliposta-yd_yeniweb.php'
   18     8        ASSIGN                                                   !7, 'http%3A%2F%2Fwww1.ptt.gov.tr%2Ftr%2Finteraktif%2FCaptchaSecurityImages.php%3Fwidth%3D100%26height%3D40%26characters%3D5'
   97     9        FETCH_R                      global              ~35     '_SERVER'
         10        FETCH_DIM_R                                      ~36     ~35, 'REQUEST_METHOD'
         11        IS_EQUAL                                                 ~36, 'POST'
         12      > JMPZ                                                     ~37, ->247
  102    13    >   FETCH_R                      global              ~38     '_POST'
         14        FETCH_DIM_R                                      ~39     ~38, 'cnpj'
         15        ASSIGN                                                   !8, ~39
  104    16        FETCH_R                      global              ~41     '_POST'
         17        FETCH_DIM_R                                      ~42     ~41, 'cnpj2'
         18        ASSIGN                                                   !9, ~42
  109    19        ASSIGN                                                   !0, 'CP021325078TR'
  110    20        ASSIGN                                                   !10, 'http%3A%2F%2Fwww1.ptt.gov.tr%2Ftr%2Finteraktif%2Fsonuc-yd.php'
  111    21        CONCAT                                           ~46     'barkod%3D', !0
         22        CONCAT                                           ~47     ~46, '%26security_code%3D'
         23        CONCAT                                           ~48     ~47, !8
         24        ASSIGN                                                   !11, ~48
  112    25        ASSIGN                                                   !12, 'Mozilla%2F5.0+%28Windows%3B+U%3B+Windows+NT+5.1%3B+en-US%3B+rv%3A1.8.1.6%29+Gecko%2F20070725+Firefox%2F2.0.0.6'
  113    26        ASSIGN                                                   !13, 'http%3A%2F%2Fwww1.ptt.gov.tr%2Ftr%2Finteraktif%2Fkayitliposta-yd_yeniweb.php'
  114    27        INIT_FCALL                                               'dirname'
         28        SEND_VAL                                                 '%2Fin%2FuUksV'
         29        DO_ICALL                                         $52     
         30        CONCAT                                           ~53     $52, '%2Freceita.txt.'
         31        ASSIGN                                                   !14, ~53
  116    32        INIT_ARRAY                                       ~55     'Referer%3A+xxx'
  117    33        CONCAT                                           ~56     'Origin%3A+', !10
         34        ADD_ARRAY_ELEMENT                                ~55     ~56
  118    35        ADD_ARRAY_ELEMENT                                ~55     'Content-Type%3A+application%2Fx-www-form-urlencoded'
  119    36        ADD_ARRAY_ELEMENT                                ~55     'Connection%3A+keep-alive'
  120    37        ADD_ARRAY_ELEMENT                                ~55     'Accept-Charset%3A+ISO-8859-1%2Cutf-8%3Bq%3D0.7%2C%2A%3Bq%3D0.3'
  121    38        ADD_ARRAY_ELEMENT                                ~55     'Cache-Control%3A+max-age%3D0'
  122    39        ADD_ARRAY_ELEMENT                                ~55     'Except%3A'
  116    40        ASSIGN                                                   !15, ~55
  125    41        FETCH_CONSTANT                                   ~58     'CURLOPT_URL'
         42        INIT_ARRAY                                       ~59     !10, ~58
  126    43        FETCH_CONSTANT                                   ~60     'CURLOPT_POST'
         44        ADD_ARRAY_ELEMENT                                ~59     1, ~60
  127    45        FETCH_CONSTANT                                   ~61     'CURLOPT_POSTFIELDS'
         46        ADD_ARRAY_ELEMENT                                ~59     !11, ~61
  128    47        FETCH_CONSTANT                                   ~62     'CURLOPT_USERAGENT'
         48        ADD_ARRAY_ELEMENT                                ~59     !12, ~62
  129    49        FETCH_CONSTANT                                   ~63     'CURLOPT_REFERER'
         50        ADD_ARRAY_ELEMENT                                ~59     !13, ~63
  130    51        FETCH_CONSTANT                                   ~64     'CURLOPT_COOKIEFILE'
         52        ADD_ARRAY_ELEMENT                                ~59     !14, ~64
  131    53        FETCH_CONSTANT                                   ~65     'CURLOPT_COOKIEJAR'
         54        ADD_ARRAY_ELEMENT                                ~59     !14, ~65
  132    55        FETCH_CONSTANT                                   ~66     'CURLOPT_FOLLOWLOCATION'
         56        ADD_ARRAY_ELEMENT                                ~59     1, ~66
  133    57        FETCH_CONSTANT                                   ~67     'CURLOPT_RETURNTRANSFER'
         58        ADD_ARRAY_ELEMENT                                ~59     1, ~67
  134    59        FETCH_CONSTANT                                   ~68     'CURLOPT_HEADER'
         60        ADD_ARRAY_ELEMENT                                ~59     0, ~68
  124    61        ASSIGN                                                   !16, ~59
  137    62        INIT_FCALL_BY_NAME                                       'curl_init'
         63        DO_FCALL                                      0  $70     
         64        ASSIGN                                                   !17, $70
  138    65        INIT_FCALL_BY_NAME                                       'curl_setopt_array'
         66        SEND_VAR_EX                                              !17
         67        SEND_VAR_EX                                              !16
         68        DO_FCALL                                      0          
  139    69        INIT_FCALL_BY_NAME                                       'curl_exec'
         70        SEND_VAR_EX                                              !17
         71        DO_FCALL                                      0  $73     
         72        ASSIGN                                                   !18, $73
  140    73        INIT_FCALL_BY_NAME                                       'curl_close'
         74        SEND_VAR_EX                                              !17
         75        DO_FCALL                                      0          
  175    76        INIT_FCALL                                               'print_r'
         77        SEND_VAR                                                 !18
         78        DO_ICALL                                                 
  196    79        INIT_FCALL                                               'fopen'
         80        SEND_VAL                                                 'temp.txt'
         81        SEND_VAL                                                 'w%2B'
         82        DO_ICALL                                         $77     
         83        ASSIGN                                                   !19, $77
  197    84        INIT_FCALL                                               'fwrite'
         85        SEND_VAR                                                 !19
         86        SEND_VAR                                                 !18
         87        DO_ICALL                                                 
  198    88        INIT_FCALL                                               'fclose'
         89        SEND_VAR                                                 !19
         90        DO_ICALL                                                 
  202    91        INIT_FCALL_BY_NAME                                       'iconv'
         92        SEND_VAL_EX                                              'iso-8859-9'
         93        SEND_VAL_EX                                              'utf-8'
         94        SEND_VAR_EX                                              !18
         95        DO_FCALL                                      0  $81     
         96        ASSIGN                                                   !18, $81
  203    97        INIT_FCALL                                               'clean_gunk'
         98        INIT_FCALL                                               'translit_turkish'
         99        SEND_VAR                                                 !18
        100        DO_FCALL                                      0  $83     
        101        SEND_VAR                                                 $83
        102        DO_FCALL                                      0  $84     
        103        ASSIGN                                                   !18, $84
  204   104        NEW                                              $86     'DOMDocument'
        105        DO_FCALL                                      0          
        106        ASSIGN                                                   !20, $86
  205   107        BEGIN_SILENCE                                    ~89     
        108        INIT_METHOD_CALL                                         !20, 'loadHTML'
        109        SEND_VAR_EX                                              !18
        110        DO_FCALL                                      0          
        111        END_SILENCE                                              ~89
  206   112        NEW                                              $91     'DOMXPATH'
        113        SEND_VAR_EX                                              !20
        114        DO_FCALL                                      0          
        115        ASSIGN                                                   !21, $91
  211   116        INIT_FCALL                                               'to_array'
        117        INIT_METHOD_CALL                                         !21, 'query'
        118        SEND_VAL_EX                                              '%28%2F%2Ftable%5B3%5D%2F%2Ftr%2F%2Ftext%28%29%29'
        119        DO_FCALL                                      0  $94     
        120        SEND_VAR                                                 $94
        121        DO_FCALL                                      0  $95     
        122        ASSIGN                                                   !3, $95
  212   123        INIT_FCALL                                               'fix_keys'
        124        INIT_FCALL                                               'array_filter'
        125        SEND_VAR                                                 !3
        126        INIT_FCALL_BY_NAME                                       'create_function'
        127        SEND_VAL_EX                                              '%24a'
        128        SEND_VAL_EX                                              'return+trim%28%24a%29%21%3D%3D%22%22%3B'
        129        DO_FCALL                                      0  $97     
        130        SEND_VAR                                                 $97
        131        DO_ICALL                                         $98     
        132        SEND_VAR                                                 $98
        133        DO_FCALL                                      0  $99     
        134        ASSIGN                                                   !3, $99
  213   135        ASSIGN                                                   !22, 0
        136      > JMP                                                      ->178
  214   137    >   INIT_FCALL                                               'trim'
        138        INIT_FCALL                                               'str_replace'
        139        SEND_VAL                                                 '++'
        140        SEND_VAL                                                 ''
        141        FETCH_DIM_R                                      ~103    !3, !22
        142        SEND_VAL                                                 ~103
        143        DO_ICALL                                         $104    
        144        SEND_VAR                                                 $104
        145        DO_ICALL                                         $105    
        146        CONCAT                                           ~106    $105, '%2C'
        147        INIT_FCALL                                               'trim'
        148        ADD                                              ~107    !22, 1
        149        FETCH_DIM_R                                      ~108    !3, ~107
        150        SEND_VAL                                                 ~108
        151        DO_ICALL                                         $109    
        152        CONCAT                                           ~110    ~106, $109
        153        CONCAT                                           ~111    ~110, '%2C'
        154        INIT_FCALL                                               'trim'
        155        ADD                                              ~112    !22, 2
        156        FETCH_DIM_R                                      ~113    !3, ~112
        157        SEND_VAL                                                 ~113
        158        DO_ICALL                                         $114    
        159        CONCAT                                           ~115    ~111, $114
        160        CONCAT                                           ~116    ~115, '%2C'
        161        INIT_FCALL                                               'trim'
        162        ADD                                              ~117    !22, 3
        163        FETCH_DIM_R                                      ~118    !3, ~117
        164        SEND_VAL                                                 ~118
        165        DO_ICALL                                         $119    
        166        CONCAT                                           ~120    ~116, $119
        167        CONCAT                                           ~121    ~120, '%2C'
        168        INIT_FCALL                                               'trim'
        169        ADD                                              ~122    !22, 4
        170        FETCH_DIM_R                                      ~123    !3, ~122
        171        SEND_VAL                                                 ~123
        172        DO_ICALL                                         $124    
        173        CONCAT                                           ~125    ~121, $124
        174        ASSIGN_DIM                                               !23
        175        OP_DATA                                                  ~125
  213   176        ADD                                              ~126    !22, 5
        177        ASSIGN                                                   !22, ~126
        178    >   COUNT                                            ~128    !3
        179        IS_SMALLER                                               !22, ~128
        180      > JMPNZ                                                    ~129, ->137
  216   181    >   INIT_FCALL                                               'var_dump'
        182        SEND_VAR                                                 !23
        183        DO_ICALL                                                 
  219   184        INIT_FCALL                                               'to_array'
        185        INIT_METHOD_CALL                                         !21, 'query'
        186        SEND_VAL_EX                                              '%28%2F%2Ftable%5B9%5D%2F%2Ftr%2F%2Ftext%28%29%29'
        187        DO_FCALL                                      0  $131    
        188        SEND_VAR                                                 $131
        189        DO_FCALL                                      0  $132    
        190        ASSIGN                                                   !24, $132
  220   191        INIT_FCALL                                               'fix_keys'
        192        INIT_FCALL                                               'array_filter'
        193        SEND_VAR                                                 !24
        194        INIT_FCALL_BY_NAME                                       'create_function'
        195        SEND_VAL_EX                                              '%24a'
        196        SEND_VAL_EX                                              'return+trim%28%24a%29%21%3D%3D%22%22%3B'
        197        DO_FCALL                                      0  $134    
        198        SEND_VAR                                                 $134
        199        DO_ICALL                                         $135    
        200        SEND_VAR                                                 $135
        201        DO_FCALL                                      0  $136    
        202        ASSIGN                                                   !24, $136
  221   203        UNSET_DIM                                                !24, 0
  222   204        UNSET_DIM                                                !24, 1
  223   205        UNSET_DIM                                                !24, 2
  224   206        INIT_FCALL                                               'fix_keys'
        207        SEND_VAR                                                 !24
        208        DO_FCALL                                      0  $138    
        209        ASSIGN                                                   !24, $138
  225   210        ASSIGN                                                   !22, 0
        211      > JMP                                                      ->239
  226   212    >   INIT_FCALL                                               'trim'
        213        INIT_FCALL                                               'str_replace'
        214        SEND_VAL                                                 '++'
        215        SEND_VAL                                                 ''
        216        FETCH_DIM_R                                      ~142    !24, !22
        217        SEND_VAL                                                 ~142
        218        DO_ICALL                                         $143    
        219        SEND_VAR                                                 $143
        220        DO_ICALL                                         $144    
        221        CONCAT                                           ~145    $144, '%2C'
        222        INIT_FCALL                                               'trim'
        223        ADD                                              ~146    !22, 1
        224        FETCH_DIM_R                                      ~147    !24, ~146
        225        SEND_VAL                                                 ~147
        226        DO_ICALL                                         $148    
        227        CONCAT                                           ~149    ~145, $148
        228        CONCAT                                           ~150    ~149, '%2C'
        229        INIT_FCALL                                               'trim'
        230        ADD                                              ~151    !22, 2
        231        FETCH_DIM_R                                      ~152    !24, ~151
        232        SEND_VAL                                                 ~152
        233        DO_ICALL                                         $153    
        234        CONCAT                                           ~154    ~150, $153
        235        ASSIGN_DIM                                               !25
        236        OP_DATA                                                  ~154
  225   237        ADD                                              ~155    !22, 3
        238        ASSIGN                                                   !22, ~155
        239    >   COUNT                                            ~157    !24
        240        IS_SMALLER                                               !22, ~157
        241      > JMPNZ                                                    ~158, ->212
  230   242    >   INIT_FCALL                                               'var_dump'
        243        SEND_VAR                                                 !25
        244        DO_ICALL                                                 
  236   245        ECHO                                                     '%3Cpre%3E'
        246      > JMP                                                      ->259
  243   247    >   INIT_FCALL                                               'get_capcha'
        248        SEND_VAR                                                 !7
        249        SEND_VAL                                                 'capcha.jpg'
        250        DO_FCALL                                      0          
  248   251        INIT_FCALL                                               'htmlentities'
        252        FETCH_R                      global              ~161    '_SERVER'
        253        FETCH_DIM_R                                      ~162    ~161, 'PHP_SELF'
        254        SEND_VAL                                                 ~162
        255        DO_ICALL                                         $163    
        256        CONCAT                                           ~164    '%3Cimg+src+%3D+%27capcha.jpg%27+%2F%3E%3Cimg+src+%3D+%27capcha2.jpg%27+%2F%3E%3Cform+action+%3D+%22', $163
        257        CONCAT                                           ~165    ~164, '%22+method+%3D+%22POST%22%3E%0A++++++++++++++captcha%0A++++++++++++++%3Cinput+name+%3D+%22cnpj%22%3E%0A++++++++++++++%3Cinput+name+%3D+%22cnpj2%22%3E%0A++++++++++++++%3Cinput+type+%3D+%22submit%22%3E%0A+++++++++%3C%2F+form%3E+'
        258        ECHO                                                     ~165
  256   259    > > RETURN                                                   1

Function fix_keys:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 12
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 12
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 11
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 11
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 12
filename:       /in/uUksV
function name:  fix_keys
number of ops:  18
compiled vars:  !0 = $array, !1 = $val, !2 = $k
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   21     0  E >   RECV_INIT                                        !0      null
   22     1      > FE_RESET_R                                       $3      !0, ->12
          2    > > FE_FETCH_R                                       ~4      $3, !1, ->12
          3    >   ASSIGN                                                   !2, ~4
   23     4        TYPE_CHECK                                  128          !1
          5      > JMPZ                                                     ~6, ->11
   24     6    >   INIT_FCALL_BY_NAME                                       'fix_keys'
          7        SEND_VAR_EX                                              !1
          8        DO_FCALL                                      0  $8      
          9        ASSIGN_DIM                                               !0, !2
         10        OP_DATA                                                  $8
   22    11    > > JMP                                                      ->2
         12    >   FE_FREE                                                  $3
   27    13        INIT_FCALL                                               'array_values'
         14        SEND_VAR                                                 !0
         15        DO_ICALL                                         $9      
         16      > RETURN                                                   $9
   28    17*     > RETURN                                                   null

End of function fix_keys

Function translit_turkish:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uUksV
function name:  translit_Turkish
number of ops:  10
compiled vars:  !0 = $inputText, !1 = $search, !2 = $replace
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   30     0  E >   RECV                                             !0      
   31     1        ASSIGN                                                   !1, <array>
   32     2        ASSIGN                                                   !2, <array>
   33     3        INIT_FCALL                                               'str_replace'
          4        SEND_VAR                                                 !1
          5        SEND_VAR                                                 !2
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                         $5      
          8      > RETURN                                                   $5
   34     9*     > RETURN                                                   null

End of function translit_turkish

Function clean_gunk:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uUksV
function name:  clean_gunk
number of ops:  9
compiled vars:  !0 = $input, !1 = $search
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   36     0  E >   RECV                                             !0      
   37     1        ASSIGN                                                   !1, <array>
   38     2        INIT_FCALL                                               'str_replace'
          3        SEND_VAR                                                 !1
          4        SEND_VAL                                                 ''
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                         $3      
          7      > RETURN                                                   $3
   39     8*     > RETURN                                                   null

End of function clean_gunk

Function to_array:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 3, Position 2 = 8
Branch analysis from position: 3
2 jumps found. (Code = 78) Position 1 = 4, Position 2 = 8
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
filename:       /in/uUksV
function name:  to_array
number of ops:  11
compiled vars:  !0 = $DomList, !1 = $array, !2 = $list
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   42     0  E >   RECV                                             !0      
   43     1        ASSIGN                                                   !1, <array>
   44     2      > FE_RESET_R                                       $4      !0, ->8
          3    > > FE_FETCH_R                                               $4, !2, ->8
   45     4    >   FETCH_OBJ_R                                      ~6      !2, 'nodeValue'
          5        ASSIGN_DIM                                               !1
          6        OP_DATA                                                  ~6
   44     7      > JMP                                                      ->3
          8    >   FE_FREE                                                  $4
   47     9      > RETURN                                                   !1
   48    10*     > RETURN                                                   null

End of function to_array

Function preview:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 7, Position 2 = 17
Branch analysis from position: 7
2 jumps found. (Code = 78) Position 1 = 8, Position 2 = 17
Branch analysis from position: 8
1 jumps found. (Code = 42) Position 1 = 7
Branch analysis from position: 7
Branch analysis from position: 17
2 jumps found. (Code = 43) Position 1 = 21, Position 2 = 26
Branch analysis from position: 21
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 26
Branch analysis from position: 17
filename:       /in/uUksV
function name:  preview
number of ops:  27
compiled vars:  !0 = $results, !1 = $result, !2 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   51     0  E >   RECV_INIT                                        !0      null
   52     1        ECHO                                                     '%3Cpre%3E'
   53     2        INIT_FCALL                                               'print_r'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                                 
   54     5        ECHO                                                     '%3Cbr%2F%3ENode+Values+%3Cbr%2F%3E'
   55     6      > FE_RESET_R                                       $4      !0, ->17
          7    > > FE_FETCH_R                                               $4, !1, ->17
   56     8    >   INIT_FCALL                                           

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
318.13 ms | 1435 KiB | 44 Q