function getURLParam(strParamName){
  var strReturn="";
  //var strHref = window.location.href;
  var strHref=document.getElementById("COsurveyPromo").src;
  if (strHref.indexOf("?")>-1){
    var strQueryString=strHref.substr(strHref.indexOf("?")).toLowerCase();
    var aQueryString=strQueryString.split("&");
    for (var iParam=0; iParam<aQueryString.length; iParam++){
      if (aQueryString[iParam].indexOf(strParamName.toLowerCase()+"=")>-1 ){
        var aParam=aQueryString[iParam].split("=");
        strReturn=aParam[1];
        break;
      }
    }
  }
  return unescape(strReturn);
} 
x = getURLParam("id"); 
sm = getURLParam("sm"); 
bg = getURLParam("bg"); 
bs = getURLParam("bs"); 
ss = getURLParam("ss"); 
var promo = new Object();
if (x && x!='') promo.survey=x;
else promo.survey=window.location.href;
promo.small_url='http://www.countingopinions.com/survey/small.swf';
if (sm && sm!='') promo.small_image = sm;
else promo.small_image = escape('http://www.countingopinions.com/survey/small.jpg');
if (ss && ss!='') {
	promo.small_width = ss;
	promo.small_height = ss;
} else {
	promo.small_width = '100';
	promo.small_height = '100';
}
promo.small_params = 'ico=' + promo.small_image;
promo.big_url = 'http://www.countingopinions.com/survey/big.swf';
if (bg && bg!='') promo.big_image = bg;
else promo.big_image = escape('http://www.countingopinions.com/survey/big.jpg');
if (bs && bs!='') {
	promo.big_width = bs;
	promo.big_height = bs;
} else {
	promo.big_width = '650';
	promo.big_height = '650';
}
promo.big_params = 'big=' + promo.big_image + '&ad_url=' + promo.survey;
function sizeup987(){
	document.getElementById('promoBig').style.top = '0px';
	document.getElementById('promoSmall').style.top = '-1000px';
}
function sizedown987(){
	document.getElementById("promoSmall").style.top = "0px";
	document.getElementById("promoBig").style.top = "-1000px";
}
promo.putObjects = function () {
// <promoSmall>
document.write('<div id="promoSmall" style="position:absolute;width:'+ promo.small_width +'px;height:'+ promo.small_height +'px;z-index:9999;right:0px;top:0px;">');
// object
document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"');
document.write(' codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0"');
document.write(' id="promoSmallObject" width="'+promo.small_width+'" height="'+promo.small_height+'">');
// object params
document.write(' <param name="allowScriptAccess" value="always"/> ');
document.write(' <param name="movie" value="'+ promo.small_url +'?'+ promo.small_params +'"/>');
document.write(' <param name="wmode" value="transparent" />');
document.write(' <param name="quality" value="high" /> ');
document.write(' <param name="FlashVars" value="'+promo.small_params+'"/>');
// embed
document.write('<embed src="'+ promo.small_url + '?' + promo.small_params +'" name="promoSmallObject" wmode="transparent" quality="high" width="'+ promo.small_width +'" height="'+ promo.small_height +'" flashvars="'+ promo.small_params +'" allowscriptaccess="always" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"></embed>');
document.write('</object></div>');
document.write('</script>');
// </promoSmall>
// <promoBig>
document.write('<div id="promoBig" style="position:absolute;width:'+ promo.big_width +'px;height:'+ promo.big_height +'px;z-index:9999;right:0px;top:0px;">');
// object
document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"');
document.write(' codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0"');
document.write(' id="promoBigObject" width="'+ promo.big_width +'" height="'+ promo.big_height +'">');
// object params
document.write(' <param name="allowScriptAccess" value="always"/> ');
document.write(' <param name="movie" value="'+ promo.big_url +'?'+ promo.big_params +'"/>');
document.write(' <param name="wmode" value="transparent"/>');
document.write(' <param name="quality" value="high" /> ');
document.write(' <param name="FlashVars" value="'+ promo.big_params +'"/>');
// embed
document.write('<embed src="'+ promo.big_url + '?' + promo.big_params +'" id="promoBigEmbed" name="promoBigObject" wmode="transparent" quality="high" width="'+ promo.big_width +'" height="'+ promo.big_height +'" flashvars="'+ promo.big_params +'" swliveconnect="true" allowscriptaccess="always" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"></embed>');
document.write('</object></div>');
// </promoBig>
setTimeout('document.getElementById("promoBig").style.top = "-1000px";',1000);
}
promo.putObjects();