jQuery获取页面所有a标签对应的href属性值

var a = [];$("nav a").each(function(){a.push($(this).attr("href"))});return a;

posted @ 2020-09-07 10:25  小心走火  阅读(2902)  评论(0编辑  收藏  举报