3v4l.org

run code in 300+ PHP versions simultaneously
<?php class EmbedRandomize { var $embed,$listapi; public function dataAPI(){ if(!empty($this->listapi)){ $api = explode(',',$this->listapi); return $api; } return []; } public function isContains($match,$string){ if(strpos($string,$match) !== false){ return true; } return false; } public function isInternalEmbed(){ $api = $this->dataAPI(); if(!empty($api)){ foreach($api 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/fsMiC
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
-------------------------------------------------------------------------------------
   52     0  E >   ASSIGN                                                   !0, 'https%3A%2F%2Fserver.omovv.com%2Fapi%2Chttps%3A%2F%2Fnode1.omovv.com%2Fapi'
   54     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'
   56     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'
   58     3        NEW                                              $7      'EmbedRandomize'
          4        DO_FCALL                                      0          
          5        ASSIGN                                                   !3, $7
   59     6        ASSIGN_OBJ                                               !3, 'listapi'
          7        OP_DATA                                                  !0
   60     8        ASSIGN_OBJ                                               !3, 'embed'
          9        OP_DATA                                                  !1
   61    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
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 10
Branch analysis from position: 3
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/fsMiC
function name:  dataAPI
number of ops:  12
compiled vars:  !0 = $api
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   ISSET_ISEMPTY_PROP_OBJ                           ~1      'listapi'
          1        BOOL_NOT                                         ~2      ~1
          2      > JMPZ                                                     ~2, ->10
    7     3    >   INIT_FCALL                                               'explode'
          4        SEND_VAL                                                 '%2C'
          5        FETCH_OBJ_R                                      ~3      'listapi'
          6        SEND_VAL                                                 ~3
          7        DO_ICALL                                         $4      
          8        ASSIGN                                                   !0, $4
    8     9      > RETURN                                                   !0
   10    10    > > RETURN                                                   <array>
   11    11*     > 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/fsMiC
function name:  isContains
number of ops:  11
compiled vars:  !0 = $match, !1 = $string
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   14     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
   15     8    > > RETURN                                                   <true>
   17     9    > > RETURN                                                   <false>
   18    10*     > RETURN                                                   null

End of function iscontains

Function isinternalembed:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 28
Branch analysis from position: 6
2 jumps found. (Code = 77) Position 1 = 7, Position 2 = 27
Branch analysis from position: 7
2 jumps found. (Code = 78) Position 1 = 8, Position 2 = 27
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 24, Position 2 = 26
Branch analysis from position: 24
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 26
1 jumps found. (Code = 42) Position 1 = 7
Branch analysis from position: 7
Branch analysis from position: 27
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 27
Branch analysis from position: 28
filename:       /in/fsMiC
function name:  isInternalEmbed
number of ops:  30
compiled vars:  !0 = $api, !1 = $value, !2 = $plugins
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   21     0  E >   INIT_METHOD_CALL                                         'dataAPI'
          1        DO_FCALL                                      0  $3      
          2        ASSIGN                                                   !0, $3
   22     3        ISSET_ISEMPTY_CV                                 ~5      !0
          4        BOOL_NOT                                         ~6      ~5
          5      > JMPZ                                                     ~6, ->28
   23     6    > > FE_RESET_R                                       $7      !0, ->27
          7    > > FE_FETCH_R                                               $7, !1, ->27
   24     8    >   INIT_FCALL                                               'str_replace'
          9        SEND_VAL                                                 '%2Fapi'
         10        SEND_VAL                                                 '%2Fplugins'
         11        INIT_FCALL                                               'trim'
         12        SEND_VAR                                                 !1
         13        DO_ICALL                                         $8      
         14        SEND_VAR                                                 $8
         15        DO_ICALL                                         $9      
         16        ASSIGN                                                   !2, $9
   25    17        INIT_METHOD_CALL                                         'isContains'
         18        SEND_VAR_EX                                              !2
         19        CHECK_FUNC_ARG                                           
         20        FETCH_OBJ_FUNC_ARG                               $11     'embed'
         21        SEND_FUNC_ARG                                            $11
         22        DO_FCALL                                      0  $12     
         23      > JMPZ                                                     $12, ->26
   26    24    >   FE_FREE                                                  $7
         25      > RETURN                                                   <true>
   23    26    > > JMP                                                      ->7
         27    >   FE_FREE                                                  $7
   30    28    > > RETURN                                                   <false>
   31    29*     > 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/fsMiC
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
-------------------------------------------------------------------------------------
   34     0  E >   INIT_METHOD_CALL                                         'dataAPI'
          1        DO_FCALL                                      0  $5      
          2        ASSIGN                                                   !0, $5
   35     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
   36    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
   37    20        ASSIGN                                                   !3, <array>
   38    21        INIT_METHOD_CALL                                         'dataAPI'
         22        DO_FCALL                                      0  $16     
         23      > FE_RESET_R                                       $17     $16, ->36
         24    > > FE_FETCH_R                                               $17, !4, ->36
   39    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
   38    35      > JMP                                                      ->24
         36    >   FE_FREE                                                  $17
   41    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
   42    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/fsMiC
function name:  modify
number of ops:  9
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   45     0  E >   INIT_METHOD_CALL                                         'isInternalEmbed'
          1        DO_FCALL                                      0  $0      
          2      > JMPZ                                                     $0, ->6
   46     3    >   INIT_METHOD_CALL                                         'randomize'
          4        DO_FCALL                                      0  $1      
          5      > RETURN                                                   $1
   48     6    >   FETCH_OBJ_R                                      ~2      'embed'
          7      > RETURN                                                   ~2
   49     8*     > RETURN                                                   null

End of function modify

End of class EmbedRandomize.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
157.59 ms | 1408 KiB | 23 Q