I have a form with the following field(this field is just one of 4)
<input type="email" name="email" id="email" size="30" class="text-input" />
If I use this in jquery the form works as expected:
var dataString = 'name='+ name + '&email=' + email + '&message=' + message + '&ip=' + ip + '&date=' + date;
However if I use this to shorten the code, the email input is totally ignored on submit.
var dataString = $('#contact').serialize();
Is this a bug or is there something Im not seeing. What is the difference between the two? If I change the email input to "text" then the form works with serialize
Using jquery 1.6.0
I had the same issue recently, and it turned out I was using jQuery 1.3.2!
Upgrading to 1.6.2 (latest) fixed it.
I suspect this later version upgraded the serialize function to recognise the new HTML5 input types.