show recaptcha after 5 attemp in php

please try this,

<?php
$attempt = isset($_SESSION['attempt'])? $_SESSION['attempt']: 0;
if($attempt >= 3){
      //show recaptcha with jquery
}
?>

Leave a Comment