[jQuery]循环遍历改变a标签的href时间:2023-03-09 16:45:18 把info类下面所有的a标签链接后天加"#article"。 jQuery(document).ready(function($){ $('.info a').each(function(){ let Ahref = $(this).attr("href") + "#article"; $(this).attr("href",Ahref); });});