This is some easy Registration Form example written in PHP.
You can configure fields and regex patterns yourself (see form.ajax.php file). That's it. You can create independent forms that way.
You can easily disable AJAX by a few little modifications, however AJAX is cool so why not to use it (with jQuery) nowadays?
Whole data can be inserted to database, no implementation was given but it's easy to extend some PDO or other stuff.
I hope you'll find it useful. I'm open to questions and comments. If my code sucks, please tell me what's wrong, as I'm learning to improve quality of my code. Thank you!
Enjoy!