<html>
<head>
<meta name="viewport" content="width=device-width" />
<title>BasicDetails</title>
</head>
<body>
<div>
<input type="text" class="details-dialog" disabled="disabled" value="Input Seeting" style="color:red" />
<input type="text" class="details-dialog" disabled="disabled" value="Design Seeting" />
<input type="text" class="details-dialog" disabled="disabled" value="Publish" />
@*<label id="lbl1" class="details-dialog" disabled="disabled" style="color:Red ; width:100%">INPUT SEETING</label>
<label id="lbl2" style="color:maroon ; width:100%">DESIGN SEETING</label>*@
@*<label id="lbl3" style="color:maroon ; width:100%">PUBLISH</label>*@*
</div>
@using (Html.BeginForm())
{
<fieldset>
@*<legend></legend>*@
<div id="label1" style="width:100% ; height:100%">
<div id="div1">
<h4>Basic Details</h4>
@Html.LabelFor(m => m.FirstName)
@Html.TextBoxFor(m => m.FirstName)
@Html.ValidationMessageFor(m => m.FirstName)
<br /><br />
@Html.LabelFor(m => m.LastName)
@Html.TextBoxFor(m => m.LastName)
@Html.ValidationMessageFor(m => m.LastName)
<div id="div2">
<h4>Address Details</h4>
@Html.LabelFor(m => m.Address)
@Html.TextBoxFor(m => m.Address)
@Html.ValidationMessageFor(m => m.Address)
@Html.LabelFor(m => m.City)
@Html.TextBoxFor(m => m.City)
@Html.ValidationMessageFor(m => m.City)
<div id="div3">
<h4>Contact Details</h4>
@Html.LabelFor(m => m.Phone)
@Html.TextBoxFor(m => m.Phone)
@Html.ValidationMessageFor(m => m.Phone)
@Html.LabelFor(m => m.Mobile)
@Html.TextBoxFor(m => m.Mobile)
@Html.ValidationMessageFor(m => m.Mobile)
<input type="button" value="submit" />
</fieldset>
<br />
<input type="button" id="prev" value="PREV" />
<input type="button" id="next" value="NEXT" />
@section Script{
Scripts.Render("~/bundles/jqueryval")
}
<script type="text/javascript">
$(document).ready(function () {
// Hide all div
//$("#div2").hide();
//$("#div3").hide();
//$("#div1").hide();
//$("#next").hide();
//$("#prev").hide();
//rough//
$("#div2").hide();
$("#div3").hide();
$("#div1").show();
$("#next").show();
$("#prev").hide();
$("#next").click(function () {
$("#prev").show();
});
//$("#spnEmp").click(function () {
// $("#div1").show();
// $("#next").show();
// $("#prev").show();
// });
//if ($("#label1 div:visible").nextAll('div').length == 1)
// $("#next").hide();
if ($("#label1 div:visible").next().length != 0)
$("#label1 div:visible").next().show().prev().hide();
else {
$("#label1 div:visible").hide();
$("#label1 div:first").show();
return false;
$("#prev").click(function () {
if ($("#label1 div:visible").prev().length != 0)
$("#label1 div:visible").prev().show().next().hide();
$("#label1 div:last").show();
//if ($("#label1 div:visible").nextAll('div').length > 0)
</script>
</body>
</html>