I have a form with many divs inside. Each div is categorized and has various fields to be filled up by the user. I want to have a flow here so that the user can fill the fields in the second div only after filling the fields in the first div. In short show the second div after filling the fields in the first div and so on.
I tried using the following code:
$("div.form1 input").each(function () {
if (this.value == "")
("div.form2").eq(1).hide();
else
("div.form2").eq(1).show();
});
and the div starts like this:
<div class="myclass" id="form1">
But haven't got any success with this. Can anyone help me with this?? Please!!