function _f2void() { return; } function _f2sleep(ms) { var start = new Date(); var now = new Date(); while(now.getTime() - start.getTime() < ms) { now = new Date(); } } function f2convert(cid, pids) { try { var img = new Image(1,1); var src = "//rd.clickshift.com/convert.gif?cid=" + escape(cid); try { if (location.protocol == 'file:') { src = "http:" + src; } } catch (ex) { } src += "&pids=" + escape(pids); // conversion_id is optional third parameter if (f2convert.arguments.length > 2) { var conversion_id = f2convert.arguments[2]; src += "&conversion_id=" + (conversion_id ? escape(conversion_id) : ''); } if (f2convert.arguments.length > 3) { if (f2convert.arguments[3]) { src += "&pof=1"; } } if (f2convert.arguments.length > 4) { var cs_data = f2convert.arguments[4]; src += "&cshift_ck=" + (cs_data ? escape(cs_data) : ''); } if (f2convert.arguments.length > 5) { var attribution = f2convert.arguments[5]; src += "&attribution=" + (attribution ? escape(attribution) : ''); } img.onload = function () { _f2void(); } img.src = src; } catch (ex) {} try { // activate custom code. Right now for ShopNBC only // possibly not supporting this anymore if (cid == 1000) { java_script = ''; document.write(java_script); } } catch(ex){} return true; } function f2_onclick_convert(cid, pids) { var img = new Image(1,1); var src = "//rd.clickshift.com/convert.gif?cid=" + escape(cid); try { if (location.protocol == 'file:') { src = "http:" + src; } } catch (ex) { } src += "&pids=" + escape(pids); // conversion_id is optional third parameter if (f2_onclick_convert.arguments.length > 2) { var conversion_id = f2_onclick_convert.arguments[2]; src += "&conversion_id=" + (conversion_id ? escape(conversion_id) : ''); } if (f2_onclick_convert.arguments.length > 3) { if (f2_onclick_convert.arguments[3]) { src += "&pof=1"; } } if (f2_onclick_convert.arguments.length > 4) { var cs_data = f2_onclick_convert.arguments[4]; src += "&cshift_ck=" + (cs_data ? escape(cs_data) : ''); } if (f2_onclick_convert.arguments.length > 5) { var attribution = f2_onclick_convert.arguments[5]; src += "&attribution=" + (attribution ? escape(attribution) : ''); } src += "&rnd=" + escape(Math.round(1E10*Math.random())); img.onload = function () { _f2void(); } img.src = src; try { if(navigator.appName != "Microsoft Internet Explorer") { // Firefox will abort image loads if a navigation // event occurs, so we'll need to slow things down // a bit. _f2sleep(500); } } catch (ex) {} return true; }