title: using javascript and php together to validate
body: <p>How do I use php and javascript together?  from doing my own research, it seems impossible.  I understand that they are different, and they each have their own special things that they do.  But let's say you are validating a form.   You use javascript to validate the form, then if there are no errors, you run php to insert a record.  How would you do this?  Is there any way to run php in javascript or call on a php method?</p>