摘要: jQuery获取Select选择的Text和Value: 语法解释: 1. $("#select_id").change(function(){//code...}); //为Select添加事件,当选择其中一项时触发 2. var checkText=$("#select_id").find("o 阅读全文
posted @ 2012-10-31 10:35 songpingyi 阅读(166) 评论(0) 推荐(0) 编辑
摘要: //遍历option和添加、移除optionfunction changeShipMethod(shipping){var len = $("select[@name=ISHIPTYPE] option").lengthif(shipping.value != "CA"){ $("select[@name=ISHIPTYPE] option").each(function(){ if($(this).val() == 111){ $(this).remove(); } });}else{ $("<option valu 阅读全文
posted @ 2012-10-31 10:20 songpingyi 阅读(141) 评论(0) 推荐(0) 编辑