我会跳到<fieldset>
与类"secound"
,但跳转不起作用。 我的代码有什么问题? 对不起,我的英语,我希望你能帮助我?
$(".next").click(function(){
textnext = "next1";
current_fs = $(this).parent();
next_fs = $(this).parent().next();
if(textnext == $(".next").val()){
next_fs = $(this).parent(".secound").next();
}
next_fs.show();
}
<script src="https://code.jquery.com/jquery-2.1.4.min.js"></script>
<fieldset style="height:100vh">
<input type="button" name="next" class="next action-button" value="next1" />
</fieldset>
<fieldset style="height:100vh" class="first">
<input type="button" name="next" class="next action-button" value="Next" />
</fieldset>
<fieldset style="height:100vh" class="secound">
<input type="button" name="next" class="next action-button" value="Next" />
</fieldset>
你缺少了)在next_fs.show(); }你写的next_fs.show(); }) – Bak
这是代码,我不会跳转到下一个字段集。我将跳转到一个类的自定义字段集。 http://thecodeplayer.com/walkthrough/jquery-multi-step-form-with-progress-bar – mirko