的情景:的onblur不火
我想觸發功能checkDOMChange
(其中隱藏ul
標籤是空) 一旦input
注入並沒有重點,但目前,該功能並不被稱爲。這是一個fiddle。
function checkDOMChange() {
if ($("div[id$='DoIQualify_financials'] div").hasClass("field-invalid")) {
if ($('.borrower1Salary_errors li').length == 0) {
jQuery("ul.borrower1Salary_errors").hide();
}
if ($('.borrower2Salary_errors li').length == 0){
jQuery("ul.borrower2Salary_errors").hide();
}
}
有錯字錯誤'函數checkDOMChange(){'不關井。檢查控制檯 –
您也有一個範圍問題。 – j08691
看到它在這裏工作:http://jsfiddle.net/vcbcq1jz/10/ –