close

[輸入框群組 checkbox+textbox ]

 

<script type="text/javascript">

    $(function () {

             $(document).on("click", 'input[name="ck1"]:checkbox', function () {
                     $('input[name="ck1"]:checkbox').on('change', function (e) {
                             if ($("input[name=AddTeachExcelCenter]:checked").val() == 'Y') {
                                         $("input[name=txt1]").prop("disabled", false);
                             }
                             else {
                                     $("input[name=txt1]").prop("disabled", true);
                             }
                 });
              });

 

    })
</script>

<div class="row">
    <div class="col-lg-6">
        <div class="input-group">
            <span class="input-group-addon">
                <input type="checkbox" id="ck1" name="ck1" value="Y" />
            </span>
            <input type="text" class="form-control" name="txt1" disabled/>
        </div>
    </div>
</div>

 

 

arrow
arrow
    全站熱搜

    米拉尤咕 發表在 痞客邦 留言(0) 人氣()