0
4

3 に答える 3

2

これを試して

   $("a").each(function() { 

          var newUrl =  $(this).attr('href')+ textOfNew + " ";

              $(this).attr('href',newUrl);

    });
于 2013-03-16T16:57:33.013 に答える
2
jQuery(function($) {
    $("a").attr('href', function(i, href) {
        return href + '/test';
    });
});

フィドル

于 2013-03-16T17:04:50.890 に答える
0
$("a").each(function() { 

    newUrl += $(this).attr("href") + textOfNew + " ";

    $(this).attr("href", newUrl);

});
于 2013-03-16T17:02:36.180 に答える