  var newwindow;
  function Querystring()
  {
	  // get the query string, ignore the ? at the front.
	  var querystring=location.search.toLowerCase().substring(1,location.search.length);

	  // parse out name/value pairs separated via &amp;
	  var args = querystring.split('&amp;');

	  // split out each name = value pair
	  for (var i=0;i<args.length;i++)
	  {
		  var pair = args[i].split('=');

		  // Fix broken unescaping
		  temp = unescape(pair[0]).split('+');
		  name = temp.join(' ');

		  temp = unescape(pair[1]).split('+');
		  value = temp.join(' ');

		  this[name]=value;
	  }

	  this.get=Querystring_get;
  }


  function Querystring_get(strKey,strDefault)
  {
	  var value=this[strKey];
	  if (value==null)
	  {
		  value=strDefault;
	  }

	  return value;
  } 

  function setCookie(name, value, expires, path, domain, secure)
  {
	  var curCookie = name + "=" + escape(value) +
		  ((expires) ? "; expires=" + expires.toGMTString() : "") +
		  ((path) ? "; path=" + path : "") +
		  ((domain) ? "; domain=" + domain : "") +
		  ((secure) ? "; secure" : "");
		  document.cookie = curCookie;
  }


  /*
	  name - name of the desired cookie
	  return string containing value of specified cookie or null
	  if cookie does not exist
  */
  
  var qs = new Querystring();

  if (qs.get("tid","") != "") {
	  deleteCookie("tid");
	  deleteCookie("tid", "/");
	  var expDate = new Date();
	  expDate.setDate(expDate.getDate()+30);
	  setCookie("tid", qs.get("tid",""), expDate, "/");
  }

  if (qs.get("source","") != "") {
	  deleteCookie("source");
	  deleteCookie("source", "/");
	  var expDate = new Date();
	  expDate.setDate(expDate.getDate()+30);
	  setCookie("source", qs.get("source",""), expDate, "/");
  }

  if (qs.get("ovmkt","") != "") {
	  deleteCookie("ovmkt");
	  deleteCookie("ovmkt", "/");
	  var expDate = new Date();
	  expDate.setDate(expDate.getDate()+30);
	  setCookie("ovmkt", qs.get("ovmkt",""), expDate, "/");
  }


  function download()
  {
      document.write('<a href=\"' + filename + '\" class=\"nav\">')
      document.write('Download')
      document.write('<\/a>')
  }

	
  function poptastic(url)
  {
	  newwindow=window.open(url,'name','height=610,width=350,scrollbars=1');
	  if (window.focus) {newwindow.focus()}
  }

  function openRefund()
  {
	Refund=window.open("http://www.winferno.com/refund.aspx","Refund","'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=223,height=263'");
  }

  function writeDate()
  {
	days = new Array(7);
	days[0] = "Sunday";
	days[1] = "Monday";
	days[2] = "Tuesday";
	days[3] = "Wednesday";
	days[4] = "Thursday";
	days[5] = "Friday";
	days[6] = "Saturday";
	months = new Array(12);
	months[0] = "January";
	months[1] = "February";
	months[2] = "March";
	months[3] = "April";
	months[4] = "May";
	months[5] = "June";
	months[6] = "July";
	months[7] = "August";
	months[8] = "September";
	months[9] = "October";
	months[10] = "November";
	months[11] = "December";
	today = new Date();
	day = days[today.getDay()];
	month = months[today.getMonth()];
	date = today.getDate();
	year=today.getYear();
	document.write (day + ", " + month + " " + date + ", " + year);
  }

  function BuyNowRadio()
  {
	  var temp;
	  var prodid;
	  var produrl = "https://secure.winferno.com/s/vstore_precheckout/msc/buy_mcafee.asp";
	  
	  var source = getCookie("source");
	  var tid = getCookie("tid");

	  if (document.RadioUpsell.prod1[0].checked)
	  {
	    prodid = document.RadioUpsell.prod1[0].value;
	  }

	  if (document.RadioUpsell.prod1[1].checked)
	  {
	    prodid = document.RadioUpsell.prod1[1].value;
	  }
	  
	  temp = "?product=" + prodid + "&tid=" + tid + "&layoutid=1&source=" + source;
	  produrl = produrl + temp;
	  window.location=produrl;
  }


  function trackingURL()
  {
	  document.all.trackframe.src = trackurl + getCookie("tid") + ".asp?ovmkt=" + getCookie("ovmkt");
  }



  function getCookie(name)
  {
	  var dc = document.cookie;
	  var prefix = name + "=";
	  var begin = dc.indexOf("; " + prefix);
	  if (begin == -1) {
		  begin = dc.indexOf(prefix);
		  if (begin != 0) return null;
	  } else
		  begin += 2;
	  var end = document.cookie.indexOf(";", begin);
	  if (end == -1)
	  end = dc.length;
	  return unescape(dc.substring(begin + prefix.length, end));
  }


  /*
	  name - name of the cookie
	  [path] - path of the cookie (must be same as path used to create cookie)
	  [domain] - domain of the cookie (must be same as domain used to create cookie)
	     path and domain default if assigned null or omitted if no explicit
		  argument proceeds
  */

  function deleteCookie(name, path, domain)
  {
	  if (getCookie(name))
	  {
		  document.cookie = name + "=" +
		  ((path) ? "; path=" + path : "") +
		  ((domain) ? "; domain=" + domain : "") +
		  "; expires=Thu, 01-Jan-70 00:00:01 GMT";
	  }
  }

  // date - any instance of the Date object
  // * hand all instances of the Date object to this function for "repairs"	