我需要檢查數組元素是否滿足給定的條件。但是我收到「is
未定義」錯誤。如何在jquery中的is()中進行條件檢查
var tempfLength = tempfArray.length;
for(var i=tempfLength-2;i> -1;i--){
alert(tempfArray[i]);
if((tempfLength >length)&&(is(tempfArray[i]==parentName))){
$(this).hide('str');
}
}
可以有一些更簡單的方法來回答這個問題。但需要更多的上下文。 – Jai