Here is my performed test task.
Task was the next:
- Check the page and see what AJAX calls it actually makes to get the data (url, variables, methods).
- Create your own PHP to make a call to check for existing email address via cURL. You need to parse the response and show only messages about existing/non-existing emails addresses.
- Implement the PHP to your page via AJAX.
- Make the appropriate data validation.
- Make sure that you have handled all errors.
- Make sure your code is well organized and well commented so other developers can easily understand it.
I used a third-party library, namely it was Validator class for data validation. You can find it by following the link Validator.
Also I used such libraries like jQuery v2.2.4 and Bootstrap v3.3.6. It included like dependencies and located in vendors folder. I used Composer for this.
Require parameters discribed in composer.json. So after cloning/downloading
the project need to run composer install
in terminal.
I will be glad to hear review of written code.