解决方法
我不这么认为,但这应该可以解决问题
$('*').filter(function(){return this.attributes.length;})
而相反:
$('*').filter(function(){return !this.attributes.length;})