simple form validation with jquery serialize() function
<pre><code>$(document).ready(function(){

$('#send').click(function() { 

var names = $('#appontment_form').serialize();

//this is how my names variable look like
//doctor=Dr.Fathmath+Shahuda&amp;date=2013-02-27&amp;time=1900+-+1700&amp;phone=

var doc = $(names).filter('doctor');

if(doc !='')
{
       $.ajax({
       type: "post",
       url:  "../../includes/jqueryRequireFiles/appointmentSave.php",
       data:names,
       success: function(data)
       { 
        $('#confir').text('Your Appointment Received..');
       }
       });
       return false;
 }
 });
});
</code></pre>

<p>I have a appontment form. when i click send link it will grab all the values in the textboxs and put it in the names variable through serialize() function. i want to filter the names variable and find out if any of the field is left not filled.. if only if then i will make the ajax part.. but its not working...any help</p>
