textareaテキストをリアルタイムでリスニングして、選択したスタイルを追加するかどうかを判断します.
3512 ワード
ポイントは
.on("input propertychange")
$(document).on("input propertychange",'[name="desc"]',function(){
$('.v1-homework-testlist').eq($(this).data('idx')).addClass('active');//
});
【jQuery】input textarea
Input textarea :【 js 】
HTML:
<textarea style="display: none" class="notifyDetail"></textarea>
JS:
/**
* textarea
*/
$(document).on("input propertychange",".notifyDetail",function(){
alert(123);
});