您是否尝试过在filter函数之外声明一个数组,然后在该数组中推送值?
var matched = []; jQuery(this).nextAll().filter(function () { matched.push(yourFilteredElement); });