jQuery change href by id code example
Example 1: get attribute value jquery href
var href = $(this).attr('href');
Example 2: jquery set href of link
$('.element').attr('href', newUrl);
Example 3: jQuery change href value
$("#someAnchorElement").attr("href", "http://www.myfancynewurl.com");
Example 4: how to edit the link in a href with jquery
$("a").attr("href", "http://www.google.com/")