Created
February 13, 2020 11:35
-
-
Save ashour/e652749d73c6bca4a8c239ea1a8c51dd to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require_once 'functions.php'; | |
require_once 'validation/rules.php'; | |
require_once 'validation/Validator.php'; | |
$validator = Validator::make($rules, $_POST); | |
if ($validator->isAllValid()) { | |
header('Location: /thank-you.php?lang=' . lang()); | |
die(); | |
} else { | |
$errors = $validator->errors(); | |
require_once 'index.php'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment