Tweaked the check.php file