开发者

Need Multiple combo boxes using AJAX

I need to display Multiple c开发者_Go百科ombo boxes using AJAX...In my form displays only one combo box and it below combo box in text "add more courses".If i click "add more courses" then i need to open another combo box and like more combo box..Please any one Help me immediately


You can try something like this with jQuery to add a new Field.

<script type="text/javascript">
    $(document).ready(function() {

        $("#addCourse").click(function() {

            var html = '<p><input type="text" name="course[]" value="" /></p>';
            $("#courses").append(html);

        });

    });
</script>

<div id="courses">
    <p>
        <input type="text" name="course[]" value="" />
    </p>
</div>

<a href="#" id="addCourse" onClick="javascript:addMore();">
    add more courses
</a>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜