3v4l.org

run code in 300+ PHP versions simultaneously
<?php require_once('config.php'); require_once('login.php'); $pagetitle='Members Area - '.$sitename; $user=$_SESSION['user_name']; if($_GET['action']=='update'){ if($_POST){ $fullname = mysql_real_escape_string($_POST['ufullname']); $fone = mysql_real_escape_string($_POST['ufone']); $addr = mysql_real_escape_string($_POST['uaddr']); $email = mysql_real_escape_string($_POST['uemail']); mysql_query("UPDATE $tbl_name SET fullname='$fullname', fone='$fone', addr='$addr', email='$email' WHERE user_name='$user'") or die(mysql_error()); header("Location: members.php?msg_gr=Your details have been updated!"); } else { $sql22="SELECT * FROM $tbl_name WHERE user_name='$user'"; $result22=mysql_query($sql22) or die(mysql_error()); $user22=mysql_fetch_array($result22); ?> require_once('header.php'); ?> <div class="content2" style="margin-top:20px;"> <?php if (isSet($_GET['msg_gr'])){ echo "<span style='display:block;margin-top:20px;text-align:center;color:green;font-weight:bold;'>".htmlentities($_GET['msg_gr'])."</span><br/>"; } ?> <?php if (isSet($responsemsg)){ echo "<span style='display:block;margin-top:20px;text-align:center;color:red;font-weight:bold;'>".htmlentities($responsemsg)."</span><br/>"; } ?> <form name="form3" method="post" action=""> <h2>Edit your Profile</h2> Fullname: <input name="ufullname" type="text" id="ufullname" value="<?=$user22['fullname']?>" /><br/> Phone: <input name="ufone" type="text" id="ufone" value="<?=$user22['fone']?>" /><br/> Address: <input name="uaddr" type="text" id="uaddr" value="<?=$user22['addr']?>" /><br/> Email: <input name="uemail" type="text" id="uemail" value="<?=$user22['email']?>" /><br/> <input type="submit" name="Submit" value="Update" /> <br/><br/> <strong>Change Password </strong>:<br/> <i>To change password, please get at the Office!</i> </form> <br/><br/><br/> <a href="members.php" >Go back</a> </div> <?php require_once('footer.php'); } } else { require_once('header.php'); if(!$_SESSION['attendance']){ $attendance='Not available'; } else { $attendance=$_SESSION['attendance']; } ?> <div class="content2"> <strong>Welcome, <?=$_SESSION['fullname']?></strong><br/> <div style="float:left;width:780px;"> <h3>What you want to do?</h3><hr/> <ul> <li><a href="misc.php?page=downloads" >Browse through our downloads</a></li> <li><a href="?action=update" >Update Profile</a></li> </ul> </div> <?php if($_SESSION['rank']){ ?> <div style="font-size:13px;float:right"> <b>Your Stats:</b><hr/> Fine: <?=$_SESSION['fine']?><br/> Fee Status: <?=$_SESSION['fee']?><br/> Last month Result: <?=$_SESSION['result_last']?><br/> Last Month Attendance: <!-- <span id="attendance" style="display:none;"> --> <?=$attendance?> <!-- </span><a href="javascript:void(0)" id="att-show" align="absmiddle"><img style="width: 56px;height: 20px;" src="images/click.gif" /></a> --><br/> </div> <br/> <?php } ?> </div> <script> $(function(){ $('a#att-show').on("click", function(){ $('#attendance').slideToggle(); }); }); </script> <?php require_once('footer.php'); } ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 11, Position 2 = 120
Branch analysis from position: 11
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 66
Branch analysis from position: 13
2 jumps found. (Code = 47) Position 1 = 58, Position 2 = 62
Branch analysis from position: 58
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 62
1 jumps found. (Code = 42) Position 1 = 119
Branch analysis from position: 119
1 jumps found. (Code = 42) Position 1 = 155
Branch analysis from position: 155
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 66
2 jumps found. (Code = 47) Position 1 = 77, Position 2 = 81
Branch analysis from position: 77
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 81
2 jumps found. (Code = 43) Position 1 = 89, Position 2 = 97
Branch analysis from position: 89
2 jumps found. (Code = 43) Position 1 = 99, Position 2 = 105
Branch analysis from position: 99
1 jumps found. (Code = 42) Position 1 = 155
Branch analysis from position: 155
Branch analysis from position: 105
Branch analysis from position: 97
Branch analysis from position: 120
2 jumps found. (Code = 43) Position 1 = 125, Position 2 = 127
Branch analysis from position: 125
1 jumps found. (Code = 42) Position 1 = 130
Branch analysis from position: 130
2 jumps found. (Code = 43) Position 1 = 138, Position 2 = 153
Branch analysis from position: 138
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 153
Branch analysis from position: 127
2 jumps found. (Code = 43) Position 1 = 138, Position 2 = 153
Branch analysis from position: 138
Branch analysis from position: 153
filename:       /in/tPcWs
function name:  (null)
number of ops:  156
compiled vars:  !0 = $pagetitle, !1 = $sitename, !2 = $user, !3 = $fullname, !4 = $fone, !5 = $addr, !6 = $email, !7 = $tbl_name, !8 = $sql22, !9 = $result22, !10 = $user22, !11 = $responsemsg, !12 = $attendance
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INCLUDE_OR_EVAL                                          'config.php', REQUIRE_ONCE
    3     1        INCLUDE_OR_EVAL                                          'login.php', REQUIRE_ONCE
    4     2        CONCAT                                           ~15     'Members+Area+-+', !1
          3        ASSIGN                                                   !0, ~15
    5     4        FETCH_R                      global              ~17     '_SESSION'
          5        FETCH_DIM_R                                      ~18     ~17, 'user_name'
          6        ASSIGN                                                   !2, ~18
    6     7        FETCH_R                      global              ~20     '_GET'
          8        FETCH_DIM_R                                      ~21     ~20, 'action'
          9        IS_EQUAL                                                 ~21, 'update'
         10      > JMPZ                                                     ~22, ->120
    7    11    >   FETCH_R                      global              ~23     '_POST'
         12      > JMPZ                                                     ~23, ->66
    8    13    >   INIT_FCALL_BY_NAME                                       'mysql_real_escape_string'
         14        CHECK_FUNC_ARG                                           
         15        FETCH_FUNC_ARG               global              $24     '_POST'
         16        FETCH_DIM_FUNC_ARG                               $25     $24, 'ufullname'
         17        SEND_FUNC_ARG                                            $25
         18        DO_FCALL                                      0  $26     
         19        ASSIGN                                                   !3, $26
    9    20        INIT_FCALL_BY_NAME                                       'mysql_real_escape_string'
         21        CHECK_FUNC_ARG                                           
         22        FETCH_FUNC_ARG               global              $28     '_POST'
         23        FETCH_DIM_FUNC_ARG                               $29     $28, 'ufone'
         24        SEND_FUNC_ARG                                            $29
         25        DO_FCALL                                      0  $30     
         26        ASSIGN                                                   !4, $30
   10    27        INIT_FCALL_BY_NAME                                       'mysql_real_escape_string'
         28        CHECK_FUNC_ARG                                           
         29        FETCH_FUNC_ARG               global              $32     '_POST'
         30        FETCH_DIM_FUNC_ARG                               $33     $32, 'uaddr'
         31        SEND_FUNC_ARG                                            $33
         32        DO_FCALL                                      0  $34     
         33        ASSIGN                                                   !5, $34
   11    34        INIT_FCALL_BY_NAME                                       'mysql_real_escape_string'
         35        CHECK_FUNC_ARG                                           
         36        FETCH_FUNC_ARG               global              $36     '_POST'
         37        FETCH_DIM_FUNC_ARG                               $37     $36, 'uemail'
         38        SEND_FUNC_ARG                                            $37
         39        DO_FCALL                                      0  $38     
         40        ASSIGN                                                   !6, $38
   12    41        INIT_FCALL_BY_NAME                                       'mysql_query'
         42        ROPE_INIT                                    13  ~41     'UPDATE+'
         43        ROPE_ADD                                      1  ~41     ~41, !7
         44        ROPE_ADD                                      2  ~41     ~41, '+SET+fullname%3D%27'
         45        ROPE_ADD                                      3  ~41     ~41, !3
         46        ROPE_ADD                                      4  ~41     ~41, '%27%2C+fone%3D%27'
         47        ROPE_ADD                                      5  ~41     ~41, !4
         48        ROPE_ADD                                      6  ~41     ~41, '%27%2C+addr%3D%27'
         49        ROPE_ADD                                      7  ~41     ~41, !5
         50        ROPE_ADD                                      8  ~41     ~41, '%27%2C+email%3D%27'
         51        ROPE_ADD                                      9  ~41     ~41, !6
         52        ROPE_ADD                                     10  ~41     ~41, '%27+WHERE+user_name%3D%27'
         53        ROPE_ADD                                     11  ~41     ~41, !2
         54        ROPE_END                                     12  ~40     ~41, '%27'
         55        SEND_VAL_EX                                              ~40
         56        DO_FCALL                                      0  $48     
         57      > JMPNZ_EX                                         ~49     $48, ->62
         58    >   INIT_FCALL_BY_NAME                                       'mysql_error'
         59        DO_FCALL                                      0  $50     
         60      > EXIT                                                     $50
         61*       BOOL                                             ~49     <true>
   13    62    >   INIT_FCALL                                               'header'
         63        SEND_VAL                                                 'Location%3A+members.php%3Fmsg_gr%3DYour+details+have+been+updated%21'
         64        DO_ICALL                                                 
         65      > JMP                                                      ->119
   15    66    >   ROPE_INIT                                     5  ~53     'SELECT+%2A+FROM+'
         67        ROPE_ADD                                      1  ~53     ~53, !7
         68        ROPE_ADD                                      2  ~53     ~53, '+WHERE+user_name%3D%27'
         69        ROPE_ADD                                      3  ~53     ~53, !2
         70        ROPE_END                                      4  ~52     ~53, '%27'
         71        ASSIGN                                                   !8, ~52
   16    72        INIT_FCALL_BY_NAME                                       'mysql_query'
         73        SEND_VAR_EX                                              !8
         74        DO_FCALL                                      0  $57     
         75        ASSIGN                                           ~58     !9, $57
         76      > JMPNZ_EX                                         ~58     ~58, ->81
         77    >   INIT_FCALL_BY_NAME                                       'mysql_error'
         78        DO_FCALL                                      0  $59     
         79      > EXIT                                                     $59
         80*       BOOL                                             ~58     <true>
   17    81    >   INIT_FCALL_BY_NAME                                       'mysql_fetch_array'
         82        SEND_VAR_EX                                              !9
         83        DO_FCALL                                      0  $60     
         84        ASSIGN                                                   !10, $60
   19    85        ECHO                                                     '%09%09%0Arequire_once%28%27header.php%27%29%3B%0A%3F%3E%0A%3Cdiv+class%3D%22content2%22+style%3D%22margin-top%3A20px%3B%22%3E%0A'
   23    86        FETCH_IS                                         ~62     '_GET'
         87        ISSET_ISEMPTY_DIM_OBJ                         0          ~62, 'msg_gr'
         88      > JMPZ                                                     ~63, ->97
         89    >   INIT_FCALL                                               'htmlentities'
         90        FETCH_R                      global              ~64     '_GET'
         91        FETCH_DIM_R                                      ~65     ~64, 'msg_gr'
         92        SEND_VAL                                                 ~65
         93        DO_ICALL                                         $66     
         94        CONCAT                                           ~67     '%3Cspan+style%3D%27display%3Ablock%3Bmargin-top%3A20px%3Btext-align%3Acenter%3Bcolor%3Agreen%3Bfont-weight%3Abold%3B%27%3E', $66
         95        CONCAT                                           ~68     ~67, '%3C%2Fspan%3E%3Cbr%2F%3E'
         96        ECHO                                                     ~68
   24    97    >   ISSET_ISEMPTY_CV                                         !11
         98      > JMPZ                                                     ~69, ->105
         99    >   INIT_FCALL                                               'htmlentities'
        100        SEND_VAR                                                 !11
        101        DO_ICALL                                         $70     
        102        CONCAT                                           ~71     '%3Cspan+style%3D%27display%3Ablock%3Bmargin-top%3A20px%3Btext-align%3Acenter%3Bcolor%3Ared%3Bfont-weight%3Abold%3B%27%3E', $70
        103        CONCAT                                           ~72     ~71, '%3C%2Fspan%3E%3Cbr%2F%3E'
        104        ECHO                                                     ~72
   25   105    >   ECHO                                                     '%3Cform+name%3D%22form3%22+method%3D%22post%22+action%3D%22%22%3E%0A%0A%3Ch2%3EEdit+your+Profile%3C%2Fh2%3E%0A%09Fullname%3A+%3Cinput+name%3D%22ufullname%22+type%3D%22text%22+id%3D%22ufullname%22+value%3D%22'
   28   106        FETCH_DIM_R                                      ~73     !10, 'fullname'
        107        ECHO                                                     ~73
        108        ECHO                                                     '%22+%2F%3E%3Cbr%2F%3E%0A%09Phone%3A+%3Cinput+name%3D%22ufone%22+type%3D%22text%22+id%3D%22ufone%22+value%3D%22'
   29   109        FETCH_DIM_R                                      ~74     !10, 'fone'
        110        ECHO                                                     ~74
        111        ECHO                                                     '%22+%2F%3E%3Cbr%2F%3E%0A%09Address%3A+%3Cinput+name%3D%22uaddr%22+type%3D%22text%22+id%3D%22uaddr%22+value%3D%22'
   30   112        FETCH_DIM_R                                      ~75     !10, 'addr'
        113        ECHO                                                     ~75
        114        ECHO                                                     '%22+%2F%3E%3Cbr%2F%3E%0A%09Email%3A+%3Cinput+name%3D%22uemail%22+type%3D%22text%22+id%3D%22uemail%22+value%3D%22'
   31   115        FETCH_DIM_R                                      ~76     !10, 'email'
        116        ECHO                                                     ~76
        117        ECHO                                                     '%22+%2F%3E%3Cbr%2F%3E%0A%09%3Cinput+type%3D%22submit%22+name%3D%22Submit%22+value%3D%22Update%22+%2F%3E%0A%0A%3Cbr%2F%3E%3Cbr%2F%3E%0A%0A%0A%0A%3Cstrong%3EChange+Password+%3C%2Fstrong%3E%3A%3Cbr%2F%3E%0A%3Ci%3ETo+change+password%2C+please+get+at+the+Office%21%3C%2Fi%3E%0A%3C%2Fform%3E%0A%0A%3Cbr%2F%3E%3Cbr%2F%3E%3Cbr%2F%3E%0A%3Ca+href%3D%22members.php%22+%3EGo+back%3C%2Fa%3E%0A%3C%2Fdiv%3E%0A%0A%0A%0A%0A%0A%0A%0A'
   53   118        INCLUDE_OR_EVAL                                          'footer.php', REQUIRE_ONCE
        119    > > JMP                                                      ->155
   56   120    >   INCLUDE_OR_EVAL                                          'header.php', REQUIRE_ONCE
   57   121        FETCH_R                      global              ~79     '_SESSION'
        122        FETCH_DIM_R                                      ~80     ~79, 'attendance'
        123        BOOL_NOT                                         ~81     ~80
        124      > JMPZ                                                     ~81, ->127
   58   125    >   ASSIGN                                                   !12, 'Not+available'
        126      > JMP                                                      ->130
   59   127    >   FETCH_R                      global              ~83     '_SESSION'
        128        FETCH_DIM_R                                      ~84     ~83, 'attendance'
        129        ASSIGN                                                   !12, ~84
   61   130    >   ECHO                                                     '%3Cdiv+class%3D%22content2%22%3E%0A%3Cstrong%3EWelcome%2C+'
   62   131        FETCH_R                      global              ~86     '_SESSION'
        132        FETCH_DIM_R                                      ~87     ~86, 'fullname'
        133        ECHO                                                     ~87
        134        ECHO                                                     '%3C%2Fstrong%3E%3Cbr%2F%3E%0A%3Cdiv+style%3D%22float%3Aleft%3Bwidth%3A780px%3B%22%3E%0A%3Ch3%3EWhat+you+want+to+do%3F%3C%2Fh3%3E%3Chr%2F%3E%0A%3Cul%3E%0A%3Cli%3E%3Ca+href%3D%22misc.php%3Fpage%3Ddownloads%22+%3EBrowse+through+our+downloads%3C%2Fa%3E%3C%2Fli%3E%0A%3Cli%3E%3Ca+href%3D%22%3Faction%3Dupdate%22+%3EUpdate+Profile%3C%2Fa%3E%3C%2Fli%3E%0A%3C%2Ful%3E%0A%3C%2Fdiv%3E%0A'
   70   135        FETCH_R                      global              ~88     '_SESSION'
        136        FETCH_DIM_R                                      ~89     ~88, 'rank'
        137      > JMPZ                                                     ~89, ->153
   71   138    >   ECHO                                                     '%3Cdiv+style%3D%22font-size%3A13px%3Bfloat%3Aright%22%3E%0A%3Cb%3EYour+Stats%3A%3C%2Fb%3E%3Chr%2F%3E%0AFine%3A+'
   73   139        FETCH_R                      global              ~90     '_SESSION'
        140        FETCH_DIM_R                                      ~91     ~90, 'fine'
        141        ECHO                                                     ~91
        142        ECHO                                                     '%3Cbr%2F%3E%0AFee+Status%3A+'
   74   143        FETCH_R                      global              ~92     '_SESSION'
        144        FETCH_DIM_R                                      ~93     ~92, 'fee'
        145        ECHO                                                     ~93
        146        ECHO                                                     '%3Cbr%2F%3E%0ALast+month+Result%3A+'
   75   147        FETCH_R                      global              ~94     '_SESSION'
        148        FETCH_DIM_R                                      ~95     ~94, 'result_last'
        149        ECHO                                                     ~95
        150        ECHO                                                     '%3Cbr%2F%3E%0ALast+Month+Attendance%3A+%3C%21--+%3Cspan+id%3D%22attendance%22+style%3D%22display%3Anone%3B%22%3E+--%3E+'
   76   151        ECHO                                                     !12
        152        ECHO                                                     '+%3C%21--+%3C%2Fspan%3E%3Ca+href%3D%22javascript%3Avoid%280%29%22+id%3D%22att-show%22+align%3D%22absmiddle%22%3E%3Cimg+style%3D%22width%3A+56px%3Bheight%3A+20px%3B%22+src%3D%22images%2Fclick.gif%22+%2F%3E%3C%2Fa%3E+--%3E%3Cbr%2F%3E%0A%3C%2Fdiv%3E%0A%3Cbr%2F%3E%0A'
   80   153    >   ECHO                                                     '%0A%0A%3C%2Fdiv%3E%0A%3Cscript%3E%0A%24%28function%28%29%7B%0A%24%28%27a%23att-show%27%29.on%28%22click%22%2C+function%28%29%7B%0A%24%28%27%23attendance%27%29.slideToggle%28%29%3B%0A%7D%29%3B%0A%7D%29%3B%0A%3C%2Fscript%3E%0A'
   91   154        INCLUDE_OR_EVAL                                          'footer.php', REQUIRE_ONCE
   93   155    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
159 ms | 1416 KiB | 17 Q