Question
AJAX Help needed for an AJAX noob
Hey there,
I'm starting to experiment with AJAX for simple form validation but am having great difficulty in getting the following working.
I'm trying to get it to count the length of a field, and respond back to an id'd span. It works if I hard code the span id into the JS file, but not if I try and implement a variable to have the span id passed into.
I have attached the code. If someone could take a look and point out where I'm going wrong, that would be greatly appreciated.
Cheers in advance,
Brad
I'm starting to experiment with AJAX for simple form validation but am having great difficulty in getting the following working.
I'm trying to get it to count the length of a field, and respond back to an id'd span. It works if I hard code the span id into the JS file, but not if I try and implement a variable to have the span id passed into.
I have attached the code. If someone could take a look and point out where I'm going wrong, that would be greatly appreciated.
Cheers in advance,
Brad