19 - PHP Online

Form of PHP Sandbox

Enter Your PHP code here for testing/debugging in the Online PHP Sandbox. As in the usual PHP files, you can also add HTML, but do not forget to add the tag <?php in the places where the PHP script should be executed.



Your result can be seen below.

Result of php executing





Full code of 19.php

  1. <?php
  2.  
  3. echo '<pre>';
  4. $x = 0;
  5. if ($x > -5) {
  6.     $x++;
  7. }
  8.  
  9. print_r($x);
  10. print_r(',  ');
  11.  
  12. if(($x>0)&&($x++ > 1)) {
  13.     $x +=7;
  14. }
  15.  
  16.  
  17. print_r($x);
  18. print_r(',  ');
  19.  
  20. $x += 10;
  21.  
  22. print_r($x);
  23. print_r(',  ');
  24.  
  25. if(($x > 10) || ($x++ > 9)) {
  26.     $x += 8;
  27. }
  28.  
  29. print_r($x);
  30. print_r(',  ');
  31.  
  32. if($x++ > 0) {
  33.     $x += 2;
  34. }
  35.  
  36. print_r($x);
  37.  
File Description
  • 19
  • PHP Code
  • 08 May-2024
  • 319 Bytes
You can Share it: