3v4l.org

run code in 300+ PHP versions simultaneously
<? /* Edit these preferences to suit your needs */ $mailto = "busernya@hotmail.com"; // insert the email address you want the form sent to $returnpage = 'thankyou.html'; // insert the name of the page/location you want the user to be returned to $sitename = '[www.busernya.com]'; // insert the site name here, it will appear in the subject of your email /* Do not edit below this line unless you know what you're doing */ $name = $_POST['name']; $email = $_POST['email'] ; $enquiry = stripslashes($_POST['query']); if (!$name) { print("<strong>Error:</strong> Please provide your name.<br/><br/><a href='javascript:history.go(-1)'>Back</a>"); exit; } if (!$email) { print("<strong>Error:</strong> Please provide an email address.<br/><br/><a href='javascript:history.go(-1)'>Back</a>"); exit; } if (!$enquiry) { print("<strong>Error:</strong> Please provide your enquiry details.<br/><br/><a href='javascript:history.go(-1)'>Back</a>"); exit; } if (!eregi("^[a-z0-9]+([-_\.]?[a-z0-9])+@[a-z0-9]+([-_\.]?[a-z0-9])+\.[a-z]{2,4}", $email)){ print("<strong>Error:</strong> this email address is not in a valid format.<br/><br/><a href='javascript:history.go(-1)'>Back</a>"); exit; } $message = "\n$name submitted the following message:\n\n$enquiry\n\nTheir contact details are as follows:\n\nName: $name\nEmail Address: $email\n\n"; mail($mailto, "$sitename Contact Form Enquiry from $name", $message, "From: $email"); header("Location: " . $returnpage); ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 17, Position 2 = 19
Branch analysis from position: 17
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 19
2 jumps found. (Code = 43) Position 1 = 21, Position 2 = 23
Branch analysis from position: 21
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 23
2 jumps found. (Code = 43) Position 1 = 25, Position 2 = 27
Branch analysis from position: 25
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 27
2 jumps found. (Code = 43) Position 1 = 33, Position 2 = 35
Branch analysis from position: 33
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 35
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/FNhu1
function name:  (null)
number of ops:  61
compiled vars:  !0 = $mailto, !1 = $returnpage, !2 = $sitename, !3 = $name, !4 = $email, !5 = $enquiry, !6 = $message
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, 'busernya%40hotmail.com'
    5     1        ASSIGN                                                   !1, 'thankyou.html'
    6     2        ASSIGN                                                   !2, '%5Bwww.busernya.com%5D'
   10     3        FETCH_R                      global              ~10     '_POST'
          4        FETCH_DIM_R                                      ~11     ~10, 'name'
          5        ASSIGN                                                   !3, ~11
   11     6        FETCH_R                      global              ~13     '_POST'
          7        FETCH_DIM_R                                      ~14     ~13, 'email'
          8        ASSIGN                                                   !4, ~14
   12     9        INIT_FCALL                                               'stripslashes'
         10        FETCH_R                      global              ~16     '_POST'
         11        FETCH_DIM_R                                      ~17     ~16, 'query'
         12        SEND_VAL                                                 ~17
         13        DO_ICALL                                         $18     
         14        ASSIGN                                                   !5, $18
   14    15        BOOL_NOT                                         ~20     !3
         16      > JMPZ                                                     ~20, ->19
   15    17    >   ECHO                                                     '%3Cstrong%3EError%3A%3C%2Fstrong%3E+Please+provide+your+name.%3Cbr%2F%3E%3Cbr%2F%3E%3Ca+href%3D%27javascript%3Ahistory.go%28-1%29%27%3EBack%3C%2Fa%3E'
   16    18      > EXIT                                                     
   18    19    >   BOOL_NOT                                         ~21     !4
         20      > JMPZ                                                     ~21, ->23
   19    21    >   ECHO                                                     '%3Cstrong%3EError%3A%3C%2Fstrong%3E+Please+provide+an+email+address.%3Cbr%2F%3E%3Cbr%2F%3E%3Ca+href%3D%27javascript%3Ahistory.go%28-1%29%27%3EBack%3C%2Fa%3E'
   20    22      > EXIT                                                     
   22    23    >   BOOL_NOT                                         ~22     !5
         24      > JMPZ                                                     ~22, ->27
   23    25    >   ECHO                                                     '%3Cstrong%3EError%3A%3C%2Fstrong%3E+Please+provide+your+enquiry+details.%3Cbr%2F%3E%3Cbr%2F%3E%3Ca+href%3D%27javascript%3Ahistory.go%28-1%29%27%3EBack%3C%2Fa%3E'
   24    26      > EXIT                                                     
   26    27    >   INIT_FCALL_BY_NAME                                       'eregi'
         28        SEND_VAL_EX                                              '%5E%5Ba-z0-9%5D%2B%28%5B-_%5C.%5D%3F%5Ba-z0-9%5D%29%2B%40%5Ba-z0-9%5D%2B%28%5B-_%5C.%5D%3F%5Ba-z0-9%5D%29%2B%5C.%5Ba-z%5D%7B2%2C4%7D'
         29        SEND_VAR_EX                                              !4
         30        DO_FCALL                                      0  $23     
         31        BOOL_NOT                                         ~24     $23
         32      > JMPZ                                                     ~24, ->35
   27    33    >   ECHO                                                     '%3Cstrong%3EError%3A%3C%2Fstrong%3E+this+email+address+is+not+in+a+valid+format.%3Cbr%2F%3E%3Cbr%2F%3E%3Ca+href%3D%27javascript%3Ahistory.go%28-1%29%27%3EBack%3C%2Fa%3E'
   28    34      > EXIT                                                     
   31    35    >   ROPE_INIT                                     9  ~26     '%0A'
         36        ROPE_ADD                                      1  ~26     ~26, !3
         37        ROPE_ADD                                      2  ~26     ~26, '+submitted+the+following+message%3A%0A%0A'
         38        ROPE_ADD                                      3  ~26     ~26, !5
         39        ROPE_ADD                                      4  ~26     ~26, '%0A%0ATheir+contact+details+are+as+follows%3A%0A%0AName%3A+'
         40        ROPE_ADD                                      5  ~26     ~26, !3
         41        ROPE_ADD                                      6  ~26     ~26, '%0AEmail+Address%3A+'
         42        ROPE_ADD                                      7  ~26     ~26, !4
         43        ROPE_END                                      8  ~25     ~26, '%0A%0A'
         44        ASSIGN                                                   !6, ~25
   33    45        INIT_FCALL                                               'mail'
         46        SEND_VAR                                                 !0
         47        ROPE_INIT                                     3  ~33     !2
         48        ROPE_ADD                                      1  ~33     ~33, '+Contact+Form+Enquiry+from+'
         49        ROPE_END                                      2  ~32     ~33, !3
         50        SEND_VAL                                                 ~32
         51        SEND_VAR                                                 !6
         52        NOP                                                      
         53        FAST_CONCAT                                      ~35     'From%3A+', !4
         54        SEND_VAL                                                 ~35
         55        DO_ICALL                                                 
   34    56        INIT_FCALL                                               'header'
         57        CONCAT                                           ~37     'Location%3A+', !1
         58        SEND_VAL                                                 ~37
         59        DO_ICALL                                                 
   35    60      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.49 ms | 1400 KiB | 19 Q