Form Validation and POST in 4 lines of code! (Flash AS3)
Today, I’m releasing a library that should make Flash Forms and Regular Expressions really easy.
After submiting, check at the result here
Simply follow the steps:
(1) add the library in the same directory as your fla file,
(2) create as many input textfields as you will need in your form, name them all differently
(3) Create a submit button and name it.
(4) Copy the code (see end of this post)
(5) Call the function addFormIInputText() for each textfield, setting up its properties. Types available: SIMPLE – EMAIL – PHONE – URL – DATE – CREDITCARD – ZIP – PASSWORD
(6) Then, in the PHP file, access the variables this way: $_POST[0], $_POST[1], etc… by order of initialization.
(7) Enjoy!
Download the source files here


