This jQuery code works half the time depending on browser. Is there a better way to write this replace. Change and href link with .zip_
to .zip
jQuery("a[href*='.zip_']").each(function() {
jQuery(this).attr("href", jQuery(this).attr("href").replace(/\.zip_/g, ".zip"));
});