3v4l.org

run code in 300+ PHP versions simultaneously
<?php class scraper { public static $response; public static $dom; // randomize useragent string public static function get_useragent() { $ua = array( "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.1 (KHTML, like Gecko) Chrome/21.0.1180.89 Safari/537.1", "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:14.0) Gecko/20100101 Firefox/14.0.1", "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_1) AppleWebKit/536.25 (KHTML, like Gecko) Version/6.0 Safari/536.25", "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0)", "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:15.0) Gecko/20100101 Firefox/15.0.1" ); shuffle($ua); $x = array_rand($ua); return $ua[$x]; } // download using curl public static function data_download($_url) { if(!function_exists('curl_init')) { die('Sorry cURL is not installed!'); } try { $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $_url); curl_setopt($ch, CURLOPT_REFERER, "http://www.google.com/"); curl_setopt($ch, CURLOPT_USERAGENT, self::get_useragent()); curl_setopt($ch, CURLOPT_HEADER, 0); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_TIMEOUT, 30); $output = curl_exec($ch); curl_close($ch); return $output; } catch(Zend_Exception $e) { echo 'Caught Exception: ' . get_class($e) . "\n"; echo 'Message: ' . $e->getMessage() . "\n"; } } public static function data_cache($url) { $cache = Zend_Registry::get('cache'); $cache_id = md5($url); try { if(!$response = $cache->load($cache_id)) { // delay execution for a few seconds at random //sleep(rand(5, 15)); $response = trim(self::data_download($url)); $response = $cache->save($response, $cache_id); $response = $cache->load($cache_id); self::$response = $response; } else { $response = $cache->load($cache_id); self::$response = $response; } } catch(Zend_Exception $e) { echo 'Caught Exception: ' . get_class($e) . "\n"; echo 'Message: ' . $e->getMessage() . "\n"; } } public static function query_css($query) { $html = self::$response; $dom = new Zend_Dom_Query($html); $results = $dom->query($query); return $results; } public static function query_xpath($query) { $html = self::$response; $dom = new Zend_Dom_Query($html); $results = $dom->queryXpath($query); ; return $results; } public static function load_pq_dom() { try { $html = self::$response; $dom = phpQuery::newDocumentHTML($html); self::$dom = $dom; } catch(Zend_Exception $e) { echo 'Caught Exception: ' . get_class($e) . "\n"; echo 'Message: ' . $e->getMessage() . "\n"; } } public static function query_pq($query) { self::load_pq_dom(); $dom = self::$dom; $dom = $dom->find($query); $result = $dom->html(); return $result; } public static function parse_table($query, $_key, $_value) { self::load_pq_dom(); $dom = self::$dom; foreach(pq($query) as $block) { $key = trim(pq($_key, $block)->text()); $value = trim(pq($_value, $block)->text()); $array[$key] = $value; } return $array; } public static function parse_list($query) { self::load_pq_dom(); $dom = self::$dom; foreach(pq($query) as $block) { $list_item = trim(pq('ul li', $block)->text()); $array[] = $list_item; } return $array; } public static function parse_options($query) { self::load_pq_dom(); $dom = self::$dom; foreach(pq($query) as $block) { $list_item = trim(pq('option', $block)->text()); $array[] = $list_item; } return $array; } public static function parse_links($query) { $dom = self::$dom; $a = self::query_css($query); foreach($a as $href) { $links[] = $href->getAttribute('href'); } return $links; } public static function setup_database($host, $db_name, $user, $password) { Zend_Loader_Autoloader::getInstance()->registerNamespace("RedBean_"); R::setup("mysql:host={$host}; dbname={$db_name}", $user, $password); } }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hAKFY
function name:  (null)
number of ops:  1
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  159     0  E > > RETURN                                                   1

Class scraper:
Function get_useragent:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hAKFY
function name:  get_useragent
number of ops:  11
compiled vars:  !0 = $ua, !1 = $x
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   ASSIGN                                                   !0, <array>
   16     1        INIT_FCALL                                               'shuffle'
          2        SEND_REF                                                 !0
          3        DO_ICALL                                                 
   17     4        INIT_FCALL                                               'array_rand'
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                         $4      
          7        ASSIGN                                                   !1, $4
   18     8        FETCH_DIM_R                                      ~6      !0, !1
          9      > RETURN                                                   ~6
   19    10*     > RETURN                                                   null

End of function get_useragent

Function data_download:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 7
1 jumps found. (Code = 62) Position 1 = -2
Found catch point at position: 57
Branch analysis from position: 57
2 jumps found. (Code = 107) Position 1 = 58, Position 2 = -2
Branch analysis from position: 58
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hAKFY
function name:  data_download
number of ops:  68
compiled vars:  !0 = $_url, !1 = $ch, !2 = $output, !3 = $e
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   21     0  E >   RECV                                             !0      
   23     1        INIT_FCALL                                               'function_exists'
          2        SEND_VAL                                                 'curl_init'
          3        DO_ICALL                                         $4      
          4        BOOL_NOT                                         ~5      $4
          5      > JMPZ                                                     ~5, ->7
   25     6    > > EXIT                                                     'Sorry+cURL+is+not+installed%21'
   29     7    >   INIT_FCALL_BY_NAME                                       'curl_init'
          8        DO_FCALL                                      0  $6      
          9        ASSIGN                                                   !1, $6
   30    10        INIT_FCALL_BY_NAME                                       'curl_setopt'
         11        SEND_VAR_EX                                              !1
         12        FETCH_CONSTANT                                   ~8      'CURLOPT_URL'
         13        SEND_VAL_EX                                              ~8
         14        SEND_VAR_EX                                              !0
         15        DO_FCALL                                      0          
   31    16        INIT_FCALL_BY_NAME                                       'curl_setopt'
         17        SEND_VAR_EX                                              !1
         18        FETCH_CONSTANT                                   ~10     'CURLOPT_REFERER'
         19        SEND_VAL_EX                                              ~10
         20        SEND_VAL_EX                                              'http%3A%2F%2Fwww.google.com%2F'
         21        DO_FCALL                                      0          
   32    22        INIT_FCALL_BY_NAME                                       'curl_setopt'
         23        SEND_VAR_EX                                              !1
         24        FETCH_CONSTANT                                   ~12     'CURLOPT_USERAGENT'
         25        SEND_VAL_EX                                              ~12
         26        INIT_STATIC_METHOD_CALL                                  'get_useragent'
         27        DO_FCALL                                      0  $13     
         28        SEND_VAR_NO_REF_EX                                       $13
         29        DO_FCALL                                      0          
   33    30        INIT_FCALL_BY_NAME                                       'curl_setopt'
         31        SEND_VAR_EX                                              !1
         32        FETCH_CONSTANT                                   ~15     'CURLOPT_HEADER'
         33        SEND_VAL_EX                                              ~15
         34        SEND_VAL_EX                                              0
         35        DO_FCALL                                      0          
   34    36        INIT_FCALL_BY_NAME                                       'curl_setopt'
         37        SEND_VAR_EX                                              !1
         38        FETCH_CONSTANT                                   ~17     'CURLOPT_RETURNTRANSFER'
         39        SEND_VAL_EX                                              ~17
         40        SEND_VAL_EX                                              <true>
         41        DO_FCALL                                      0          
   35    42        INIT_FCALL_BY_NAME                                       'curl_setopt'
         43        SEND_VAR_EX                                              !1
         44        FETCH_CONSTANT                                   ~19     'CURLOPT_TIMEOUT'
         45        SEND_VAL_EX                                              ~19
         46        SEND_VAL_EX                                              30
         47        DO_FCALL                                      0          
   36    48        INIT_FCALL_BY_NAME                                       'curl_exec'
         49        SEND_VAR_EX                                              !1
         50        DO_FCALL                                      0  $21     
         51        ASSIGN                                                   !2, $21
   37    52        INIT_FCALL_BY_NAME                                       'curl_close'
         53        SEND_VAR_EX                                              !1
         54        DO_FCALL                                      0          
   38    55      > RETURN                                                   !2
         56*       JMP                                                      ->67
   40    57  E > > CATCH                                       last         'Zend_Exception'
   42    58    >   GET_CLASS                                        ~24     !3
         59        CONCAT                                           ~25     'Caught+Exception%3A+', ~24
         60        CONCAT                                           ~26     ~25, '%0A'
         61        ECHO                                                     ~26
   43    62        INIT_METHOD_CALL                                         !3, 'getMessage'
         63        DO_FCALL                                      0  $27     
         64        CONCAT                                           ~28     'Message%3A+', $27
         65        CONCAT                                           ~29     ~28, '%0A'
         66        ECHO                                                     ~29
   45    67      > RETURN                                                   null

End of function data_download

Function data_cache:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 34
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 40
Branch analysis from position: 40
1 jumps found. (Code = 42) Position 1 = 51
Branch analysis from position: 51
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 34
1 jumps found. (Code = 42) Position 1 = 51
Branch analysis from position: 51
Found catch point at position: 41
Branch analysis from position: 41
2 jumps found. (Code = 107) Position 1 = 42, Position 2 = -2
Branch analysis from position: 42
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hAKFY
function name:  data_cache
number of ops:  52
compiled vars:  !0 = $url, !1 = $cache, !2 = $cache_id, !3 = $response, !4 = $e
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   46     0  E >   RECV                                             !0      
   48     1        INIT_STATIC_METHOD_CALL                                  'Zend_Registry', 'get'
          2        SEND_VAL_EX                                              'cache'
          3        DO_FCALL                                      0  $5      
          4        ASSIGN                                                   !1, $5
   49     5        INIT_FCALL                                               'md5'
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                         $7      
          8        ASSIGN                                                   !2, $7
   52     9        INIT_METHOD_CALL                                         !1, 'load'
         10        SEND_VAR_EX                                              !2
         11        DO_FCALL                                      0  $9      
         12        ASSIGN                                           ~10     !3, $9
         13        BOOL_NOT                                         ~11     ~10
         14      > JMPZ                                                     ~11, ->34
   56    15    >   INIT_FCALL                                               'trim'
         16        INIT_STATIC_METHOD_CALL                                  'data_download'
         17        SEND_VAR                                                 !0
         18        DO_FCALL                                      0  $12     
         19        SEND_VAR                                                 $12
         20        DO_ICALL                                         $13     
         21        ASSIGN                                                   !3, $13
   57    22        INIT_METHOD_CALL                                         !1, 'save'
         23        SEND_VAR_EX                                              !3
         24        SEND_VAR_EX                                              !2
         25        DO_FCALL                                      0  $15     
         26        ASSIGN                                                   !3, $15
   58    27        INIT_METHOD_CALL                                         !1, 'load'
         28        SEND_VAR_EX                                              !2
         29        DO_FCALL                                      0  $17     
         30        ASSIGN                                                   !3, $17
   59    31        ASSIGN_STATIC_PROP                                       'response'
         32        OP_DATA                                                  !3
         33      > JMP                                                      ->40
   63    34    >   INIT_METHOD_CALL                                         !1, 'load'
         35        SEND_VAR_EX                                              !2
         36        DO_FCALL                                      0  $20     
         37        ASSIGN                                                   !3, $20
   64    38        ASSIGN_STATIC_PROP                                       'response'
         39        OP_DATA                                                  !3
         40    > > JMP                                                      ->51
   67    41  E > > CATCH                                       last         'Zend_Exception'
   69    42    >   GET_CLASS                                        ~23     !4
         43        CONCAT                                           ~24     'Caught+Exception%3A+', ~23
         44        CONCAT                                           ~25     ~24, '%0A'
         45        ECHO                                                     ~25
   70    46        INIT_METHOD_CALL                                         !4, 'getMessage'
         47        DO_FCALL                                      0  $26     
         48        CONCAT                                           ~27     'Message%3A+', $26
         49        CONCAT                                           ~28     ~27, '%0A'
         50        ECHO                                                     ~28
   72    51    > > RETURN                                                   null

End of function data_cache

Function query_css:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hAKFY
function name:  query_css
number of ops:  13
compiled vars:  !0 = $query, !1 = $html, !2 = $dom, !3 = $results
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   73     0  E >   RECV                                             !0      
   75     1        FETCH_STATIC_PROP_R          unknown             ~4      'response'
          2        ASSIGN                                                   !1, ~4
   76     3        NEW                                              $6      'Zend_Dom_Query'
          4        SEND_VAR_EX                                              !1
          5        DO_FCALL                                      0          
          6        ASSIGN                                                   !2, $6
   77     7        INIT_METHOD_CALL                                         !2, 'query'
          8        SEND_VAR_EX                                              !0
          9        DO_FCALL                                      0  $9      
         10        ASSIGN                                                   !3, $9
   78    11      > RETURN                                                   !3
   79    12*     > RETURN                                                   null

End of function query_css

Function query_xpath:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hAKFY
function name:  query_xpath
number of ops:  13
compiled vars:  !0 = $query, !1 = $html, !2 = $dom, !3 = $results
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   80     0  E >   RECV                                             !0      
   82     1        FETCH_STATIC_PROP_R          unknown             ~4      'response'
          2        ASSIGN                                                   !1, ~4
   83     3        NEW                                              $6      'Zend_Dom_Query'
          4        SEND_VAR_EX                                              !1
          5        DO_FCALL                                      0          
          6        ASSIGN                                                   !2, $6
   84     7        INIT_METHOD_CALL                                         !2, 'queryXpath'
          8        SEND_VAR_EX                                              !0
          9        DO_FCALL                                      0  $9      
         10        ASSIGN                                                   !3, $9
   86    11      > RETURN                                                   !3
   87    12*     > RETURN                                                   null

End of function query_xpath

Function load_pq_dom:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 19
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
Found catch point at position: 9
Branch analysis from position: 9
2 jumps found. (Code = 107) Position 1 = 10, Position 2 = -2
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hAKFY
function name:  load_pq_dom
number of ops:  20
compiled vars:  !0 = $html, !1 = $dom, !2 = $e
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   92     0  E >   FETCH_STATIC_PROP_R          unknown             ~3      'response'
          1        ASSIGN                                                   !0, ~3
   93     2        INIT_STATIC_METHOD_CALL                                  'phpQuery', 'newDocumentHTML'
          3        SEND_VAR_EX                                              !0
          4        DO_FCALL                                      0  $5      
          5        ASSIGN                                                   !1, $5
   94     6        ASSIGN_STATIC_PROP                                       'dom'
          7        OP_DATA                                                  !1
          8      > JMP                                                      ->19
   96     9  E > > CATCH                                       last         'Zend_Exception'
   98    10    >   GET_CLASS                                        ~8      !2
         11        CONCAT                                           ~9      'Caught+Exception%3A+', ~8
         12        CONCAT                                           ~10     ~9, '%0A'
         13        ECHO                                                     ~10
   99    14        INIT_METHOD_CALL                                         !2, 'getMessage'
         15        DO_FCALL                                      0  $11     
         16        CONCAT                                           ~12     'Message%3A+', $11
         17        CONCAT                                           ~13     ~12, '%0A'
         18        ECHO                                                     ~13
  101    19    > > RETURN                                                   null

End of function load_pq_dom

Function query_pq:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hAKFY
function name:  query_pq
number of ops:  14
compiled vars:  !0 = $query, !1 = $dom, !2 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  102     0  E >   RECV                                             !0      
  104     1        INIT_STATIC_METHOD_CALL                                  'load_pq_dom'
          2        DO_FCALL                                      0          
  105     3        FETCH_STATIC_PROP_R          unknown             ~4      'dom'
          4        ASSIGN                                                   !1, ~4
  106     5        INIT_METHOD_CALL                                         !1, 'find'
          6        SEND_VAR_EX                                              !0
          7        DO_FCALL                                      0  $6      
          8        ASSIGN                                                   !1, $6
  107     9        INIT_METHOD_CALL                                         !1, 'html'
         10        DO_FCALL                                      0  $8      
         11        ASSIGN                                                   !2, $8
  108    12      > RETURN                                                   !2
  109    13*     > RETURN                                                   null

End of function query_pq

Function parse_table:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 11, Position 2 = 35
Branch analysis from position: 11
2 jumps found. (Code = 78) Position 1 = 12, Position 2 = 35
Branch analysis from position: 12
1 jumps found. (Code = 42) Position 1 = 11
Branch analysis from position: 11
Branch analysis from position: 35
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 35
filename:       /in/hAKFY
function name:  parse_table
number of ops:  38
compiled vars:  !0 = $query, !1 = $_key, !2 = $_value, !3 = $dom, !4 = $block, !5 = $key, !6 = $value, !7 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  110     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
  112     3        INIT_STATIC_METHOD_CALL                                  'load_pq_dom'
          4        DO_FCALL                                      0          
  113     5        FETCH_STATIC_PROP_R          unknown             ~9      'dom'
          6        ASSIGN                                                   !3, ~9
  114     7        INIT_FCALL_BY_NAME                                       'pq'
          8        SEND_VAR_EX                                              !0
          9        DO_FCALL                                      0  $11     
         10      > FE_RESET_R                                       $12     $11, ->35
         11    > > FE_FETCH_R                                               $12, !4, ->35
  116    12    >   INIT_FCALL                                               'trim'
         13        INIT_FCALL_BY_NAME                                       'pq'
         14        SEND_VAR_EX                                              !1
         15        SEND_VAR_EX                                              !4
         16        DO_FCALL                                      0  $13     
         17        INIT_METHOD_CALL                                         $13, 'text'
         18        DO_FCALL                                      0  $14     
         19        SEND_VAR                                                 $14
         20        DO_ICALL                                         $15     
         21        ASSIGN                                                   !5, $15
  117    22        INIT_FCALL                                               'trim'
         23        INIT_FCALL_BY_NAME                                       'pq'
         24        SEND_VAR_EX                                              !2
         25        SEND_VAR_EX                                              !4
         26        DO_FCALL                                      0  $17     
         27        INIT_METHOD_CALL                                         $17, 'text'
         28        DO_FCALL                                      0  $18     
         29        SEND_VAR                                                 $18
         30        DO_ICALL                                         $19     
         31        ASSIGN                                                   !6, $19
  118    32        ASSIGN_DIM                                               !7, !5
         33        OP_DATA                                                  !6
  114    34      > JMP                                                      ->11
         35    >   FE_FREE                                                  $12
  120    36      > RETURN                                                   !7
  121    37*     > RETURN                                                   null

End of function parse_table

Function parse_list:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 9, Position 2 = 23
Branch analysis from position: 9
2 jumps found. (Code = 78) Position 1 = 10, Position 2 = 23
Branch analysis from position: 10
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
Branch analysis from position: 23
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 23
filename:       /in/hAKFY
function name:  parse_list
number of ops:  26
compiled vars:  !0 = $query, !1 = $dom, !2 = $block, !3 = $list_item, !4 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  122     0  E >   RECV                                             !0      
  124     1        INIT_STATIC_METHOD_CALL                                  'load_pq_dom'
          2        DO_FCALL                                      0          
  125     3        FETCH_STATIC_PROP_R          unknown             ~6      'dom'
          4        ASSIGN                                                   !1, ~6
  126     5        INIT_FCALL_BY_NAME                                       'pq'
          6        SEND_VAR_EX                                              !0
          7        DO_FCALL                                      0  $8      
          8      > FE_RESET_R                                       $9      $8, ->23
          9    > > FE_FETCH_R                                               $9, !2, ->23
  128    10    >   INIT_FCALL                                               'trim'
         11        INIT_FCALL_BY_NAME                                       'pq'
         12        SEND_VAL_EX                                              'ul+li'
         13        SEND_VAR_EX                                              !2
         14        DO_FCALL                                      0  $10     
         15        INIT_METHOD_CALL                                         $10, 'text'
         16        DO_FCALL                                      0  $11     
         17        SEND_VAR                                                 $11
         18        DO_ICALL                                         $12     
         19        ASSIGN                                                   !3, $12
  129    20        ASSIGN_DIM                                               !4
         21        OP_DATA                                                  !3
  126    22      > JMP                                                      ->9
         23    >   FE_FREE                                                  $9
  131    24      > RETURN                                                   !4
  132    25*     > RETURN                                                   null

End of function parse_list

Function parse_options:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 9, Position 2 = 23
Branch analysis from position: 9
2 jumps found. (Code = 78) Position 1 = 10, Position 2 = 23
Branch analysis from position: 10
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
Branch analysis from position: 23
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 23
filename:       /in/hAKFY
function name:  parse_options
number of ops:  26
compiled vars:  !0 = $query, !1 = $dom, !2 = $block, !3 = $list_item, !4 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  133     0  E >   RECV                                             !0      
  135     1        INIT_STATIC_METHOD_CALL                                  'load_pq_dom'
          2        DO_FCALL                                      0          
  136     3        FETCH_STATIC_PROP_R          unknown             ~6      'dom'
          4        ASSIGN                                                   !1, ~6
  137     5        INIT_FCALL_BY_NAME                                       'pq'
          6        SEND_VAR_EX                                              !0
          7        DO_FCALL                                      0  $8      
          8      > FE_RESET_R                                       $9      $8, ->23
          9    > > FE_FETCH_R                                               $9, !2, ->23
  139    10    >   INIT_FCALL                                               'trim'
         11        INIT_FCALL_BY_NAME                                       'pq'
         12        SEND_VAL_EX                                              'option'
         13        SEND_VAR_EX                                              !2
         14        DO_FCALL                                      0  $10     
         15        INIT_METHOD_CALL                                         $10, 'text'
         16        DO_FCALL                                      0  $11     
         17        SEND_VAR                                                 $11
         18        DO_ICALL                                         $12     
         19        ASSIGN                                                   !3, $12
  140    20        ASSIGN_DIM                                               !4
         21        OP_DATA                                                  !3
  137    22      > JMP                                                      ->9
         23    >   FE_FREE                                                  $9
  142    24      > RETURN                                                   !4
  143    25*     > RETURN                                                   null

End of function parse_options

Function parse_links:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 8, Position 2 = 15
Branch analysis from position: 8
2 jumps found. (Code = 78) Position 1 = 9, Position 2 = 15
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 8
Branch analysis from position: 8
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 15
filename:       /in/hAKFY
function name:  parse_links
number of ops:  18
compiled vars:  !0 = $query, !1 = $dom, !2 = $a, !3 = $href, !4 = $links
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  144     0  E >   RECV                                             !0      
  146     1        FETCH_STATIC_PROP_R          unknown             ~5      'dom'
          2        ASSIGN                                                   !1, ~5
  147     3        INIT_STATIC_METHOD_CALL                                  'query_css'
          4        SEND_VAR                                                 !0
          5        DO_FCALL                                      0  $7      
          6        ASSIGN                                                   !2, $7
  148     7      > FE_RESET_R                                       $9      !2, ->15
          8    > > FE_FETCH_R                                               $9, !3, ->15
  150     9    >   INIT_METHOD_CALL                                         !3, 'getAttribute'
         10        SEND_VAL_EX                                              'href'
         11        DO_FCALL                                      0  $11     
         12        ASSIGN_DIM                                               !4
         13        OP_DATA                                                  $11
  148    14      > JMP                                                      ->8
         15    >   FE_FREE                                                  $9
  152    16      > RETURN                                                   !4
  153    17*     > RETURN                                                   null

End of function parse_links

Function setup_database:
Finding entry p

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
157.14 ms | 1428 KiB | 23 Q