how is this jquery app validating the username? (3rd party script)
Posted
by SarmenHB
on Stack Overflow
See other posts from Stack Overflow
or by SarmenHB
Published on 2010-02-05T00:23:07Z
Indexed on
2010/05/26
13:01 UTC
Read the original article
Hit count: 273
The tutorial that I'm trying to figure out is this:
http://www.position-absolute.com/articles/jquery-form-validator-because-form-validation-is-a-mess/
The username
field looks like this:
<input value="" class="validate[required,custom[noSpecialCaracters],length[0,20],ajax[ajaxUser]]" type="text" name="user" id="user" />
That <input>
field has a class item named ajax[ajaxUser]
which has its rules contained in this script (jquery.validationEngine-en.js
).
The snippet for that item looks like this:
"ajaxUser":{
"file":"validateUser.php",
"extraData":"name=eric",
"alertTextOk":"* This user is available",
"alertTextLoad":"* Loading, please wait",
"alertText":"* This user is already taken"},
What I can't figure out at all is how its PHP page is working which is validateUser.php
. Where are all those post fields coming from? I looked around and can't find a field with those names.
Thanks
© Stack Overflow or respective owner