process.php 302 B

1234567891011121314
  1. <?php
  2. // Begin the session
  3. session_start();
  4. // To avoid case conflicts, make the input uppercase and check against the session value
  5. // If it's correct, echo '1' as a string
  6. if(strtoupper($_GET['captcha']) == $_SESSION['captcha_id'])
  7. echo 'true';
  8. // Else echo '0' as a string
  9. else
  10. echo 'false';
  11. ?>