fixed apply.php