now taking the names lengths into account
This commit is contained in:
parent
8bd3c81237
commit
7bd7ba8f5f
@ -47,12 +47,16 @@ if ($_SERVER["REQUEST_METHOD"] == "POST") {
|
||||
|
||||
if (empty(trim($_POST["first_name"]))) {
|
||||
$first_name_err = "Please input your first name.";
|
||||
} else if (strlen(trim($_POST["first_name"])) > 255){
|
||||
$first_name_err = "Too long.";
|
||||
} else {
|
||||
$first_name = trim($_POST["first_name"]);
|
||||
}
|
||||
|
||||
if (empty(trim($_POST["last_name"]))) {
|
||||
$last_name_err = "Please input your last name.";
|
||||
} else if (strlen(trim($_POST["last_name"])) > 255){
|
||||
$last_name_err = "Too long.";
|
||||
} else {
|
||||
$last_name = trim($_POST["last_name"]);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user