3v4l.org

run code in 300+ PHP versions simultaneously
<?php class EmbedRandomize { var $embed,$listapi; public function dataAPI(){ $api = explode(',',$this->listapi); return $api; } public function isContains($match,$string){ if(strpos($string,$match) !== false){ return true; } return false; } public function isInternalEmbed(){ foreach($this->dataAPI() as $value){ $plugins = str_replace('/api','/plugins',trim($value)); if($this->isContains($plugins,$this->embed)){ return true; } } return false; } public function randomize(){ $api = $this->dataAPI(); $numserver = mt_rand(0,(count($api)-1)); $data = str_replace('/api','/plugins',trim($api[$numserver])); $list = array(); foreach($this->dataAPI() as $value){ $list[] = str_replace('/api','/plugins',trim($value)); } return str_replace($list,$data,$this->embed); } public function modify(){ if($this->isInternalEmbed()){ return $this->randomize(); } return $this->embed; } } $apiconfig = 'https://server.omovv.com/api,https://node1.omovv.com/api'; $embed = '<iframe src="https://server.omovv.com/plugins/openload/embed.php?id=2GqeLBWdH61NiJuXNrfChmCoM8s7InY0nh9y7d2g2AoXhoRwE4hbyIJxvAtLdbH70zNq1VAHDLphboTenncx68hn7mcN7FODrBWGSuix" frameborder="0" scrolling="no" allowfullscreen="true" webkitallowfullscreen="true" mozallowfullscreen="true"></iframe>'; $embed2 = '<iframe src="https://oload.stream/plugins/openload/embed.php?id=2GqeLBWdH61NiJuXNrfChmCoM8s7InY0nh9y7d2g2AoXhoRwE4hbyIJxvAtLdbH70zNq1VAHDLphboTenncx68hn7mcN7FODrBWGSuix" frameborder="0" scrolling="no" allowfullscreen="true" webkitallowfullscreen="true" mozallowfullscreen="true"></iframe>'; $video = new EmbedRandomize(); $video->listapi = $apiconfig; $video->embed = $embed; echo $video->modify();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ZFDPd
function name:  (null)
number of ops:  14
compiled vars:  !0 = $apiconfig, !1 = $embed, !2 = $embed2, !3 = $video
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   46     0  E >   ASSIGN                                                   !0, 'https%3A%2F%2Fserver.omovv.com%2Fapi%2Chttps%3A%2F%2Fnode1.omovv.com%2Fapi'
   48     1        ASSIGN                                                   !1, '%3Ciframe+src%3D%22https%3A%2F%2Fserver.omovv.com%2Fplugins%2Fopenload%2Fembed.php%3Fid%3D2GqeLBWdH61NiJuXNrfChmCoM8s7InY0nh9y7d2g2AoXhoRwE4hbyIJxvAtLdbH70zNq1VAHDLphboTenncx68hn7mcN7FODrBWGSuix%22+frameborder%3D%220%22+scrolling%3D%22no%22+allowfullscreen%3D%22true%22+webkitallowfullscreen%3D%22true%22+mozallowfullscreen%3D%22true%22%3E%3C%2Fiframe%3E'
   50     2        ASSIGN                                                   !2, '%3Ciframe+src%3D%22https%3A%2F%2Foload.stream%2Fplugins%2Fopenload%2Fembed.php%3Fid%3D2GqeLBWdH61NiJuXNrfChmCoM8s7InY0nh9y7d2g2AoXhoRwE4hbyIJxvAtLdbH70zNq1VAHDLphboTenncx68hn7mcN7FODrBWGSuix%22+frameborder%3D%220%22+scrolling%3D%22no%22+allowfullscreen%3D%22true%22+webkitallowfullscreen%3D%22true%22+mozallowfullscreen%3D%22true%22%3E%3C%2Fiframe%3E'
   52     3        NEW                                              $7      'EmbedRandomize'
          4        DO_FCALL                                      0          
          5        ASSIGN                                                   !3, $7
   53     6        ASSIGN_OBJ                                               !3, 'listapi'
          7        OP_DATA                                                  !0
   54     8        ASSIGN_OBJ                                               !3, 'embed'
          9        OP_DATA                                                  !1
   55    10        INIT_METHOD_CALL                                         !3, 'modify'
         11        DO_FCALL                                      0  $12     
         12        ECHO                                                     $12
         13      > RETURN                                                   1

Class EmbedRandomize:
Function dataapi:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ZFDPd
function name:  dataAPI
number of ops:  8
compiled vars:  !0 = $api
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   INIT_FCALL                                               'explode'
          1        SEND_VAL                                                 '%2C'
          2        FETCH_OBJ_R                                      ~1      'listapi'
          3        SEND_VAL                                                 ~1
          4        DO_ICALL                                         $2      
          5        ASSIGN                                                   !0, $2
    7     6      > RETURN                                                   !0
    8     7*     > RETURN                                                   null

End of function dataapi

Function iscontains:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 9
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 9
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ZFDPd
function name:  isContains
number of ops:  11
compiled vars:  !0 = $match, !1 = $string
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   11     2        INIT_FCALL                                               'strpos'
          3        SEND_VAR                                                 !1
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $2      
          6        TYPE_CHECK                                  1018          $2
          7      > JMPZ                                                     ~3, ->9
   12     8    > > RETURN                                                   <true>
   14     9    > > RETURN                                                   <false>
   15    10*     > RETURN                                                   null

End of function iscontains

Function isinternalembed:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 3, Position 2 = 23
Branch analysis from position: 3
2 jumps found. (Code = 78) Position 1 = 4, Position 2 = 23
Branch analysis from position: 4
2 jumps found. (Code = 43) Position 1 = 20, Position 2 = 22
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 22
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 23
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 23
filename:       /in/ZFDPd
function name:  isInternalEmbed
number of ops:  26
compiled vars:  !0 = $value, !1 = $plugins
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   18     0  E >   INIT_METHOD_CALL                                         'dataAPI'
          1        DO_FCALL                                      0  $2      
          2      > FE_RESET_R                                       $3      $2, ->23
          3    > > FE_FETCH_R                                               $3, !0, ->23
   19     4    >   INIT_FCALL                                               'str_replace'
          5        SEND_VAL                                                 '%2Fapi'
          6        SEND_VAL                                                 '%2Fplugins'
          7        INIT_FCALL                                               'trim'
          8        SEND_VAR                                                 !0
          9        DO_ICALL                                         $4      
         10        SEND_VAR                                                 $4
         11        DO_ICALL                                         $5      
         12        ASSIGN                                                   !1, $5
   20    13        INIT_METHOD_CALL                                         'isContains'
         14        SEND_VAR_EX                                              !1
         15        CHECK_FUNC_ARG                                           
         16        FETCH_OBJ_FUNC_ARG                               $7      'embed'
         17        SEND_FUNC_ARG                                            $7
         18        DO_FCALL                                      0  $8      
         19      > JMPZ                                                     $8, ->22
   21    20    >   FE_FREE                                                  $3
         21      > RETURN                                                   <true>
   18    22    > > JMP                                                      ->3
         23    >   FE_FREE                                                  $3
   24    24      > RETURN                                                   <false>
   25    25*     > RETURN                                                   null

End of function isinternalembed

Function randomize:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 24, Position 2 = 36
Branch analysis from position: 24
2 jumps found. (Code = 78) Position 1 = 25, Position 2 = 36
Branch analysis from position: 25
1 jumps found. (Code = 42) Position 1 = 24
Branch analysis from position: 24
Branch analysis from position: 36
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 36
filename:       /in/ZFDPd
function name:  randomize
number of ops:  45
compiled vars:  !0 = $api, !1 = $numserver, !2 = $data, !3 = $list, !4 = $value
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   28     0  E >   INIT_METHOD_CALL                                         'dataAPI'
          1        DO_FCALL                                      0  $5      
          2        ASSIGN                                                   !0, $5
   29     3        INIT_FCALL                                               'mt_rand'
          4        SEND_VAL                                                 0
          5        COUNT                                            ~7      !0
          6        SUB                                              ~8      ~7, 1
          7        SEND_VAL                                                 ~8
          8        DO_ICALL                                         $9      
          9        ASSIGN                                                   !1, $9
   30    10        INIT_FCALL                                               'str_replace'
         11        SEND_VAL                                                 '%2Fapi'
         12        SEND_VAL                                                 '%2Fplugins'
         13        INIT_FCALL                                               'trim'
         14        FETCH_DIM_R                                      ~11     !0, !1
         15        SEND_VAL                                                 ~11
         16        DO_ICALL                                         $12     
         17        SEND_VAR                                                 $12
         18        DO_ICALL                                         $13     
         19        ASSIGN                                                   !2, $13
   31    20        ASSIGN                                                   !3, <array>
   32    21        INIT_METHOD_CALL                                         'dataAPI'
         22        DO_FCALL                                      0  $16     
         23      > FE_RESET_R                                       $17     $16, ->36
         24    > > FE_FETCH_R                                               $17, !4, ->36
   33    25    >   INIT_FCALL                                               'str_replace'
         26        SEND_VAL                                                 '%2Fapi'
         27        SEND_VAL                                                 '%2Fplugins'
         28        INIT_FCALL                                               'trim'
         29        SEND_VAR                                                 !4
         30        DO_ICALL                                         $19     
         31        SEND_VAR                                                 $19
         32        DO_ICALL                                         $20     
         33        ASSIGN_DIM                                               !3
         34        OP_DATA                                                  $20
   32    35      > JMP                                                      ->24
         36    >   FE_FREE                                                  $17
   35    37        INIT_FCALL                                               'str_replace'
         38        SEND_VAR                                                 !3
         39        SEND_VAR                                                 !2
         40        FETCH_OBJ_R                                      ~21     'embed'
         41        SEND_VAL                                                 ~21
         42        DO_ICALL                                         $22     
         43      > RETURN                                                   $22
   36    44*     > RETURN                                                   null

End of function randomize

Function modify:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 6
Branch analysis from position: 3
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ZFDPd
function name:  modify
number of ops:  9
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   39     0  E >   INIT_METHOD_CALL                                         'isInternalEmbed'
          1        DO_FCALL                                      0  $0      
          2      > JMPZ                                                     $0, ->6
   40     3    >   INIT_METHOD_CALL                                         'randomize'
          4        DO_FCALL                                      0  $1      
          5      > RETURN                                                   $1
   42     6    >   FETCH_OBJ_R                                      ~2      'embed'
          7      > RETURN                                                   ~2
   43     8*     > RETURN                                                   null

End of function modify

End of class EmbedRandomize.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.2 ms | 1412 KiB | 23 Q