3v4l.org

run code in 300+ PHP versions simultaneously
<?php session_start(); extract(@$_SESSION); include('mysql.php'); extract($_POST); require_once 'tools/HTMLPurifier.standalone.php'; if (@$editFlag != "1"){ $author = $userID; $config = HTMLPurifier_Config::createDefault(); $purifier = new HTMLPurifier($config); $clean_html = $purifier->purify($userContent); $clean_html = mysqli_real_escape_string($link, $clean_html); $stmt = $link->prepare("INSERT INTO userContent (section, author, content) VALUES (?, ?, ?)"); $stmt->bind_param("iis", $section, $author, $clean_html); if ($stmt->execute() === TRUE) { } else { echo "Error: " . $sql . "<br>" . $link->error; } } ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 19, Position 2 = 56
Branch analysis from position: 19
2 jumps found. (Code = 43) Position 1 = 50, Position 2 = 51
Branch analysis from position: 50
1 jumps found. (Code = 42) Position 1 = 56
Branch analysis from position: 56
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 51
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 56
filename:       /in/4Cse1
function name:  (null)
number of ops:  57
compiled vars:  !0 = $author, !1 = $userID, !2 = $config, !3 = $purifier, !4 = $clean_html, !5 = $userContent, !6 = $link, !7 = $stmt, !8 = $section, !9 = $sql
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'session_start'
          1        DO_ICALL                                                 
    3     2        INIT_FCALL                                               'extract'
          3        BEGIN_SILENCE                                    ~11     
          4        FETCH_R                      global              ~12     '_SESSION'
          5        END_SILENCE                                              ~11
          6        SEND_VAL                                                 ~12
          7        DO_ICALL                                                 
    4     8        INCLUDE_OR_EVAL                                          'mysql.php', INCLUDE
    5     9        INIT_FCALL                                               'extract'
         10        FETCH_W                      global              $15     '_POST'
         11        SEND_REF                                                 $15
         12        DO_ICALL                                                 
    7    13        INCLUDE_OR_EVAL                                          'tools%2FHTMLPurifier.standalone.php', REQUIRE_ONCE
    9    14        BEGIN_SILENCE                                    ~18     
         15        FETCH_R                      local               ~19     'editFlag'
         16        END_SILENCE                                              ~18
         17        IS_NOT_EQUAL                                             ~19, '1'
         18      > JMPZ                                                     ~20, ->56
   10    19    >   ASSIGN                                                   !0, !1
   12    20        INIT_STATIC_METHOD_CALL                                  'HTMLPurifier_Config', 'createDefault'
         21        DO_FCALL                                      0  $22     
         22        ASSIGN                                                   !2, $22
   13    23        NEW                                              $24     'HTMLPurifier'
         24        SEND_VAR_EX                                              !2
         25        DO_FCALL                                      0          
         26        ASSIGN                                                   !3, $24
   14    27        INIT_METHOD_CALL                                         !3, 'purify'
         28        SEND_VAR_EX                                              !5
         29        DO_FCALL                                      0  $27     
         30        ASSIGN                                                   !4, $27
   16    31        INIT_FCALL_BY_NAME                                       'mysqli_real_escape_string'
         32        SEND_VAR_EX                                              !6
         33        SEND_VAR_EX                                              !4
         34        DO_FCALL                                      0  $29     
         35        ASSIGN                                                   !4, $29
   19    36        INIT_METHOD_CALL                                         !6, 'prepare'
         37        SEND_VAL_EX                                              'INSERT+INTO+userContent+%28section%2C+author%2C+content%29+VALUES+%28%3F%2C+%3F%2C+%3F%29'
         38        DO_FCALL                                      0  $31     
         39        ASSIGN                                                   !7, $31
   20    40        INIT_METHOD_CALL                                         !7, 'bind_param'
         41        SEND_VAL_EX                                              'iis'
         42        SEND_VAR_EX                                              !8
         43        SEND_VAR_EX                                              !0
         44        SEND_VAR_EX                                              !4
         45        DO_FCALL                                      0          
   22    46        INIT_METHOD_CALL                                         !7, 'execute'
         47        DO_FCALL                                      0  $34     
         48        TYPE_CHECK                                    8          $34
         49      > JMPZ                                                     ~35, ->51
         50    > > JMP                                                      ->56
   25    51    >   CONCAT                                           ~36     'Error%3A+', !9
         52        CONCAT                                           ~37     ~36, '%3Cbr%3E'
         53        FETCH_OBJ_R                                      ~38     !6, 'error'
         54        CONCAT                                           ~39     ~37, ~38
         55        ECHO                                                     ~39
   29    56    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
181.29 ms | 1392 KiB | 17 Q