This is my JS code to validate a form.

How do I validate more than one variable at a time?

<script>
function validateForm()
{
var x=document.forms["myForm"]["title"].value;
if (x===null || x==="")
{
alert("First name must be filled out");
return false;
}
}
</script>