我有一些代码:
$(xml).find("strengths").each(function() {
//Code
//How can i escape from this block based on a condition.
});
我怎么才能根据条件逃脱挡路的"每个"代码呢?
更新:
如果我们有这样的东西会怎么样:
$(xml).find("strengths").each(function() {
$(this).each(function() {
//I want to break out from both each loops at the same time.
});
});
是否有可能从内部的"每个"功能中突破两个"每个"功能?
# 19.03.2013
If you want to continue instead of break out
return true;