3v4l.org

run code in 300+ PHP versions simultaneously
<? $title = "ดูซีรี่ย์ฝรั่ง&nbsp;Arrow Season 3 Ep.1-1"; $title = trim(trim($title, chr(0xC2).chr(0xA0))); echo $title; $title = html_entity_decode($title); echo $title; $title = strtolower($title); echo $title; $pattern = array("~\s*(season)\s*(\d+[-]?[0-9]*).*\s*(?:ep[.]?|episode)\s*(\d+[-]?[0-9]*)(\s*)~", "~\s*(?:ep[.]?|episode)\s*(\d+[-]?[0-9]*)(\s*)~"); $title = preg_replace($pattern, array(" $1 $2 ep. $3"," ep. $1"), $title, -1); $title = ucwords($title); $episodename = str_replace("’","'",$title); $pttr = '/[ก-๙]/ui'; $new_str = preg_replace($pttr, '', $episodename); $new_str = preg_replace('/\s+/', ' ', $new_str); $new_str = str_replace('..', '', $new_str); $new_str = trim($new_str); $episode = $new_str; echo $episode; ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/JfhrY
function name:  (null)
number of ops:  64
compiled vars:  !0 = $title, !1 = $pattern, !2 = $episodename, !3 = $pttr, !4 = $new_str, !5 = $episode
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%E0%B8%94%E0%B8%B9%E0%B8%8B%E0%B8%B5%E0%B8%A3%E0%B8%B5%E0%B9%88%E0%B8%A2%E0%B9%8C%E0%B8%9D%E0%B8%A3%E0%B8%B1%E0%B9%88%E0%B8%87%26nbsp%3BArrow+Season+3+Ep.1-1'
    4     1        INIT_FCALL                                               'trim'
          2        INIT_FCALL                                               'trim'
          3        SEND_VAR                                                 !0
          4        SEND_VAL                                                 '%C2%A0'
          5        DO_ICALL                                         $7      
          6        SEND_VAR                                                 $7
          7        DO_ICALL                                         $8      
          8        ASSIGN                                                   !0, $8
    5     9        ECHO                                                     !0
    6    10        INIT_FCALL                                               'html_entity_decode'
         11        SEND_VAR                                                 !0
         12        DO_ICALL                                         $10     
         13        ASSIGN                                                   !0, $10
    7    14        ECHO                                                     !0
    8    15        INIT_FCALL                                               'strtolower'
         16        SEND_VAR                                                 !0
         17        DO_ICALL                                         $12     
         18        ASSIGN                                                   !0, $12
    9    19        ECHO                                                     !0
   10    20        ASSIGN                                                   !1, <array>
   11    21        INIT_FCALL                                               'preg_replace'
         22        SEND_VAR                                                 !1
         23        SEND_VAL                                                 <array>
         24        SEND_VAR                                                 !0
         25        SEND_VAL                                                 -1
         26        DO_ICALL                                         $15     
         27        ASSIGN                                                   !0, $15
   12    28        INIT_FCALL                                               'ucwords'
         29        SEND_VAR                                                 !0
         30        DO_ICALL                                         $17     
         31        ASSIGN                                                   !0, $17
   14    32        INIT_FCALL                                               'str_replace'
         33        SEND_VAL                                                 '%E2%80%99'
         34        SEND_VAL                                                 '%27'
         35        SEND_VAR                                                 !0
         36        DO_ICALL                                         $19     
         37        ASSIGN                                                   !2, $19
   15    38        ASSIGN                                                   !3, '%2F%5B%E0%B8%81-%E0%B9%99%5D%2Fui'
   16    39        INIT_FCALL                                               'preg_replace'
         40        SEND_VAR                                                 !3
         41        SEND_VAL                                                 ''
         42        SEND_VAR                                                 !2
         43        DO_ICALL                                         $22     
         44        ASSIGN                                                   !4, $22
   17    45        INIT_FCALL                                               'preg_replace'
         46        SEND_VAL                                                 '%2F%5Cs%2B%2F'
         47        SEND_VAL                                                 '+'
         48        SEND_VAR                                                 !4
         49        DO_ICALL                                         $24     
         50        ASSIGN                                                   !4, $24
   18    51        INIT_FCALL                                               'str_replace'
         52        SEND_VAL                                                 '..'
         53        SEND_VAL                                                 ''
         54        SEND_VAR                                                 !4
         55        DO_ICALL                                         $26     
         56        ASSIGN                                                   !4, $26
   19    57        INIT_FCALL                                               'trim'
         58        SEND_VAR                                                 !4
         59        DO_ICALL                                         $28     
         60        ASSIGN                                                   !4, $28
   20    61        ASSIGN                                                   !5, !4
   21    62        ECHO                                                     !5
   22    63      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
162.3 ms | 1400 KiB | 25 Q