(function() { var temp = '[[215404,"wondershare.com/",24,215404],[712,"www.bestbuy.com",156074,10014],[160582,"adorama.com",156074,1036],[157431,"logitech.com",156074,8585],[217838,"logitechg.com/en-us",156074,11355],[211162,"gotprint.com",1,44480],[216123,"levenger.com",156052,9601],[209138,"videoscribe.co",156178,8913],[213814,"videoscribe.co",156178,18708],[213660,"supcase.com",156300,68388],[156813,"walmart.com",156074,9383],[212470,"www.batteriesplus.com",1,45126]]'; if (temp.length != 0) { var text = temp.replace(/"/g, '\"'); text = text.replace(/\s/g, ''); text = JSON.parse(text); var flex_convert_domains = text; var flex_user_id = 1276468; var fcd_len = flex_convert_domains.length; var atags = document.getElementsByTagName("a"), len = atags.length; while (len--) { for (i = 0; i < fcd_len; i++) { var do_break = false; var domains = flex_convert_domains[i][1].split("|"); for ( j = 0; j < domains.length; j++ ) { var du = new URL("http://" + domains[j]); if ((atags[len].host == du.host || atags[len].host == 'www.' + du.host ) && (du.pathname.length <= 1 || atags[len].pathname.startsWith(du.pathname))) { atags[len]["href"] = "https://track.flexlinks.com/g.ashx?foid=" + flex_convert_domains[i][2]+ "." + flex_convert_domains[i][3] +"&trid="+flex_user_id+"."+flex_convert_domains[i][0] + "&foc=19&fot=9999&fos=6" + "&url=" + encodeURIComponent(atags[len]["href"]); do_break = true; break; } } if (do_break) { break; } } } } })();