var pollClosed2250037 = false;
var PDV_POLLRAND2250037 = false;

var PDV_a2250037 = "";
var PDV_o2250037 = "";
var PDV_id2250037 = 2250037;
var PDV_pt2250037 = 0;
var PDV_po2250037 = 0;
var PDV_s2250037 = 71486;
var PDV_b2250037 = 1;
var PDV_l2250037 = 0;
var PDV_pr2250037 = 0;
var PDV_w2250037 = 2250037;
var PDV_share2250037 = 1;
var PDV_expire2250037 = 7257600;

var PDV_sl2250037 = 0;
var PDV_va2250037 = 16;

var PDV_lnk2250037 = 0;



var PDV_def2250037 = '#PDI_container2250037 .pds-box {} #PDI_container2250037 .pds-box-outer {} #PDI_container2250037 .pds-box-inner {} #PDI_container2250037 .pds-box-top {} #PDI_container2250037  .pds-question {} #PDI_container2250037 .pds-question-outer {} #PDI_container2250037 .pds-question-inner {} #PDI_container2250037 .pds-question-top {} #PDI_container2250037 .pds-answer {} #PDI_container2250037 .pds-answer label{} #PDI_container2250037 .pds-radiobutton {} #PDI_container2250037 .pds-checkbox {} #PDI_container2250037 .pds-textfield {} #PDI_container2250037 .pds-answer-feedback {} #PDI_container2250037 .pds-answer-feedback-bar {} #PDI_container2250037 .pds-answer-feedback img {} #PDI_container2250037 .pds-vote {} #PDI_container2250037 .pds-votebutton-outer {} #PDI_container2250037 .pds-vote a {} #PDI_container2250037 input.pds-votebutton {} #PDI_container2250037  input.pds-votebutton:hover {} #PDI_container2250037  input.pds-votebutton-pack {} #PDI_container2250037 .pds-totalvotes-outer {} #PDI_container2250037 .pds-totalvotes-inner {} #PDI_container2250037 div {margin:0;padding:0;}';

var PDV_POLL_q2250037 = 'Select one of the following'; var PDV_POLL_medType2250037 = '0'; var PDV_POLL_medID2250037 = '';
var PDV_A2250037 = new Array();


  PDV_A2250037[0] = new Array(4); PDV_A2250037[0][0] = "11011991"; PDV_A2250037[0][1] = "Cap and Trade";   PDV_A2250037[0][2] = "0"; PDV_A2250037[0][3] = "";

  PDV_A2250037[1] = new Array(4); PDV_A2250037[1][0] = "11011992"; PDV_A2250037[1][1] = "Deficit Reduction";   PDV_A2250037[1][2] = "0"; PDV_A2250037[1][3] = "";

  PDV_A2250037[2] = new Array(4); PDV_A2250037[2][0] = "11011993"; PDV_A2250037[2][1] = "Health Care Reform";   PDV_A2250037[2][2] = "0"; PDV_A2250037[2][3] = "";

  PDV_A2250037[3] = new Array(4); PDV_A2250037[3][0] = "11011994"; PDV_A2250037[3][1] = "Job Creation";   PDV_A2250037[3][2] = "0"; PDV_A2250037[3][3] = "";

  PDV_A2250037[4] = new Array(4); PDV_A2250037[4][0] = "11011995"; PDV_A2250037[4][1] = "Military Operations in Afghanistan";   PDV_A2250037[4][2] = "0"; PDV_A2250037[4][3] = "";


var PDV_l1_2250037 = 'View Results';
var PDV_l2_2250037 = 'Other:';
var PDV_l3_2250037  = '';

  
var PDV_l4_2250037 = 'Please choose an answer first!';

var PDV_l12_2250037  = 'Share This';

var PDV_l12_2250037 = 'Share This';


//v2.75 26/July/10
var protocol = document.location.protocol;
var a2a_track_pub = 'polldaddy';
var a2a_no_3p = 1;
var PD_ck2250037 = 0;
var PD_ck_name2250037 = 'PD_poll_2250037';

if (pollClosed2250037 == false)
 {
    var PDV_server2250037 = protocol + '//polls.polldaddy.com';
    var AA2250037 = new Array();
    var PDV_html2250037 = '<div style="margin-bottom: 0px; margin-top: 0px;" name="PDI_form2250037" id="PDI_form2250037"><div class="pds-box"><div class="pds-box-outer"><div class="pds-box-inner"><div class="pds-box-top"><div class="pds-question"><div class="pds-question-outer"><div class="pds-question-inner"><div class="pds-question-top">' + PDV_POLL_medID2250037 + ' ' + unescape_HTML_2250037( PDV_POLL_q2250037 ) + '</div></div></div></div><div class="pds-answer"><span id="pds-answer2250037"></span>';
    if (PDV_po2250037 == 1)
    {
		PDV_html2250037 += '<span class="pds-answer-group">';
		
        if (PDV_pt2250037 == 0) {
            PDV_html2250037 += '<span class="pds-answer-input"><input type="radio" name="PDI_answer2250037" id="PDI_answerOther2250037" value="other" class="pds-radiobutton"/></span>';
        }
        PDV_html2250037 += '<label for="PDI_answerOther2250037" class="pds-other-label"><span class="pds-answer-span">' + PDV_l2_2250037 + '</span></label><span class="pds-answer-other"><br/><input class="pds-textfield" type="text" maxlength="80" id="PDI_OtherText2250037" name="PDI_OtherText2250037" onclick="PDI_checkOther2250037();" onchange="PDI_checkOther2250037(true);" /></span>';

		PDV_html2250037 += '<span class="pds-clear"></span>';
		PDV_html2250037 += '</span>';
    }

    PDV_html2250037 += '</div><div class="pds-vote"><div class="pds-votebutton-outer">';

    if ( PDV_l3_2250037 == '' )
    {
		PDV_l3_2250037 = 'Vote';
    }
	
	if ( PDV_s2250037 < 99 || PDV_def2250037.indexOf('input.pds-votebutton') != -1 )	
	{
		if (PDV_l3_2250037 == 'Vote' || PDV_l3_2250037 == '')
	    {
	        PDV_html2250037 += '<input type="button" class="pds-votebutton" style="border:none;cursor: pointer;" src="' + ( is_secure() ? 'https://polldaddy' : 'http://i.polldaddy' ) + '.com/polls/spacer.gif" onclick="PD_vote2250037(0);">';
	    }
	    else
	    {
	        PDV_html2250037 += '<input type="button" class="pds-votebutton-pack" value="' + PDV_l3_2250037 + '"  onclick="PD_vote2250037(0);" />';
	    }
	}
	else
	{
		PDV_html2250037 += '<a href="javascript:PD_vote2250037(0);" id="pd-vote-button2250037" class="pds-vote-button"><span>' + PDV_l3_2250037 + '</span></a>';
	}

	PDV_html2250037 += '<span class="pds-links">';

    if (PDV_pr2250037 == 2) {
        PDV_html2250037 += '<br/>';
    }
    else {
        PDV_html2250037 += '<a href="javascript:PD_vote2250037(1);" class="pds-view-results">' + PDV_l1_2250037 + '</a><br/>';
    }

	if( typeof PDV_share2250037 != "undefined") {
		if (PDV_share2250037 == 1 ) {
			PDV_html2250037 += '<a class="a2a_dd pds-share"  href="javascript:">' + PDV_l12_2250037 + '</a>';
		}
	}
	
    if (PDV_lnk2250037 == 1) {
        PDV_html2250037 += '<a href="' + protocol + '//polldaddy.com/signup-now/?ad=poll-front" target="_blank" class="pds-pd-link">Create A Poll</a>';
    }

	PDV_html2250037 += '<span class="pds-clear"></span>';
	PDV_html2250037 += '</span><span class="pds-clear"></span>';
	
    PDV_html2250037 += '</div></div></div></div></div></div></div>';

    for (PDV_x = 0; PDV_x < PDV_A2250037.length; PDV_x++)
    {
        if (PDV_pt2250037 == 0)
        {
            AA2250037[PDV_x] = '<span class="pds-answer-group"><span class="pds-answer-input"><input class="pds-radiobutton" type="radio" id="PDI_answer' + PDV_A2250037[PDV_x][0] + '" value="' + PDV_A2250037[PDV_x][0] + '" name="PDI_answer2250037" /></span><label for="PDI_answer' + PDV_A2250037[PDV_x][0] + '" class="pds-input-label"><span class="pds-answer-span">' + unescape_HTML_2250037( PDV_A2250037[PDV_x][1] ) + '</span></label>' + PDV_A2250037[PDV_x][3] + '<span class="pds-clear"></span><br/></span>';
        }
        else
        {
            AA2250037[PDV_x] = '<span class="pds-answer-group"><span class="pds-answer-input"><input class="pds-checkbox" type="checkbox" id="PDI_answer' + PDV_A2250037[PDV_x][0] + '" value="' + PDV_A2250037[PDV_x][0] + '" name="PDI_answer' + PDV_A2250037[PDV_x][0] + '" onclick="javascript:PDF_mc2250037(this);" /></span><label for="PDI_answer' + PDV_A2250037[PDV_x][0] + '" class="pds-input-label"><span class="pds-answer-span">' + unescape_HTML_2250037( PDV_A2250037[PDV_x][1] ) + '</span></label>' + PDV_A2250037[PDV_x][3] + '<span class="pds-clear"></span><br/></span>';
        }
    }
}

function PDF_mc2250037(obj){
	if ( PDV_pt2250037 > 1 ){
		var nc = 0;
		for (i = 0; i < AA2250037.length; i++)
	    {
	        r = document.getElementById(AA2250037[i].substring(AA2250037[i].indexOf('id=') + 4, AA2250037[i].indexOf('"', AA2250037[i].indexOf('id=') + 4)));
	        if (r.type == "checkbox" && r.checked) { nc += 1; }
	    }
	
		if (PDV_po2250037 == 1)
	    {
			var otherText = document.getElementById("PDI_OtherText2250037").value;
			if( otherText.length > 0 ) { nc += 1; }	
		}		
		
		if ( nc > PDV_pt2250037 ){
			obj.checked = false;
			obj.disabled = true;
		}
		
		if ( nc >= PDV_pt2250037 ){
			for (i = 0; i < AA2250037.length; i++)
		    {
		        r = document.getElementById(AA2250037[i].substring(AA2250037[i].indexOf('id=') + 4, AA2250037[i].indexOf('"', AA2250037[i].indexOf('id=') + 4)));
		        if (r.type == "checkbox" && !r.checked) { r.disabled = true; }
		    }
		}
		else{
			if (PDV_po2250037 == 1) { document.getElementById("PDI_OtherText2250037").disabled=false; }
			for (i = 0; i < AA2250037.length; i++)
		    {
		        r = document.getElementById(AA2250037[i].substring(AA2250037[i].indexOf('id=') + 4, AA2250037[i].indexOf('"', AA2250037[i].indexOf('id=') + 4)));
		        if (r.type == "checkbox" && !r.checked) { r.disabled = false; }
		    }
		}
	}
}

function PDF_a2250037()
 {
    PDF_o2250037();
    var r;
    if (PDV_pt2250037 == 0)
    {
    	for (var i = 0; i < AA2250037.length; i++)
        {
            r = document.getElementById(AA2250037[i].substring(AA2250037[i].indexOf('id=') + 4, AA2250037[i].indexOf('"', AA2250037[i].indexOf('id=') + 4)));
            if (r.checked) {
                return r.value + ",";
            }
        }
        r = document.getElementById("PDI_answerOther2250037");
        if (r) {
            if (r.checked) {
                return r.value + ",";
            } else {
                return '';
            }
        } else {
            return "";
        }
    }
    else
    {
        for (i = 0; i < AA2250037.length; i++)
        {
            r = document.getElementById(AA2250037[i].substring(AA2250037[i].indexOf('id=') + 4, AA2250037[i].indexOf('"', AA2250037[i].indexOf('id=') + 4)));
            if (r.type == "checkbox" && r.checked)
            {
                PDV_a2250037 = PDV_a2250037 + r.value + ",";
            }
        }
        return PDV_a2250037;
    }
}
function PDF_o2250037(r) {
    if (PDV_po2250037 == 1) {
        PDV_o2250037 = document.getElementById("PDI_OtherText2250037").value;
    }
}
function PDI_checkOther2250037( lostfocus )
 {
	var reset = false;
	if( lostfocus ){
		var ot = document.getElementById("PDI_OtherText2250037").value;
		if( ot.length == 0 ){ reset = true; }
	}
	
    if (PDV_pt2250037 == 0)
    {
		if(lostfocus && reset){ document.getElementById("PDI_answerOther2250037").checked = false; }
		else{ document.getElementById("PDI_answerOther2250037").checked = true; }
    }
	else if ( PDV_pt2250037 > 1 ){
		var nc = 1;
		obj = document.getElementById("PDI_OtherText2250037");
		if(lostfocus && reset){ nc = 0; }
		
		for (i = 0; i < AA2250037.length; i++)
	    {
	        r = document.getElementById(AA2250037[i].substring(AA2250037[i].indexOf('id=') + 4, AA2250037[i].indexOf('"', AA2250037[i].indexOf('id=') + 4)));
	        if (r.type == "checkbox" && r.checked) { nc += 1; }
	    }

		if ( nc > PDV_pt2250037 ){
			obj.disabled=true;
			obj.value='';
			for (i = 0; i < AA2250037.length; i++)
		    {
		        r = document.getElementById(AA2250037[i].substring(AA2250037[i].indexOf('id=') + 4, AA2250037[i].indexOf('"', AA2250037[i].indexOf('id=') + 4)));
		        if (r.type == "checkbox" && !r.checked) { r.disabled = true; }
		    }
		}
		else if( nc < PDV_pt2250037 ){
			obj.disabled=false;
			for (i = 0; i < AA2250037.length; i++)
		    {
		        r = document.getElementById(AA2250037[i].substring(AA2250037[i].indexOf('id=') + 4, AA2250037[i].indexOf('"', AA2250037[i].indexOf('id=') + 4)));
		        if (r.type == "checkbox" && !r.checked) { r.disabled = false; }
		    }
		}
	}
}
function PD_vote2250037(R)
 {
    var randomnumber = Math.floor(Math.random() * 11);
    var tags = pd_get_tags2250037();
    if (R == 1)
    {
        var s = document.createElement("SCRIPT");
        s.charset = "utf-8";
        s.src = PDV_server2250037 + "/vote-js.php?s=" + PDV_s2250037 + "&vr=1&b=" + PDV_b2250037 + "&p=" + PDV_id2250037 + "&l=" + PDV_l2250037 + "&sl=" + PDV_sl2250037 + "&pr=" + PDV_pr2250037 + "&pt=" + PDV_pt2250037 + "&va=" + PDV_va2250037 + "&cookie=" + PD_ck2250037 + "&rdm=" + randomnumber + "&url=" + escape(location.href) + "&w=" + PDV_w2250037 + ( tags.length > 0 ? '&tags=' + tags : '' );
        var h = document.getElementsByTagName("head").item(0);
        h.appendChild(s);
    }
    else
    {
        if (PDV_b2250037 > 0 && PD_ck2250037 == 0 ) {
            Set_Cookie2250037(PD_ck_name2250037, 'true', 0, '/', '', '');
        }
        PDV_a2250037 = '';
        PDV_a2250037 = PDF_a2250037(document.getElementById("PDI_form2250037"));
        if (PDV_a2250037.length == 0 && PDV_o2250037.length == 0)
        {
            alert(PDV_l4_2250037);
        }
        else
        {
			if ( PDV_def2250037.indexOf('input.pds-votebutton') == -1 ) {
				document.getElementById('pd-vote-button2250037').className = 'pds-vote-button-load';
			}
	
            var s = document.createElement("SCRIPT");
            s.charset = "utf-8";
            s.src = PDV_server2250037 + "/vote-js.php?s=" + PDV_s2250037 + "&b=" + PDV_b2250037 + "&p=" + PDV_id2250037 + "&a=" + PDV_a2250037 + "&o=" + PDV_o2250037 + "&l=" + PDV_l2250037 + "&sl=" + PDV_sl2250037 + "&pr=" + PDV_pr2250037 + "&pt=" + PDV_pt2250037 + "&va=" + PDV_va2250037 + "&cookie=" + PD_ck2250037 + "&rdm=" + randomnumber + "&url=" + escape(location.href) + "&w=" + PDV_w2250037 + ( tags.length > 0 ? '&tags=' + tags : '' );
            var h = document.getElementsByTagName("head").item(0);
            h.appendChild(s);
        }
    }
}

function pd_get_tags2250037() {
	if( typeof pd_tags == "undefined" ) return '';
	var tags = '';
					
	for ( var key in pd_tags )
		tags += pd_url_encode2250037( key ) + ':' + pd_url_encode2250037( pd_tags[ key ] ) + ';';
		
	return tags.slice(0,-1);
}

function pd_url_encode2250037( s ) {
	return encodeURIComponent( s ).replace( /\%20/g, '+' ).replace( /!/g, '%21' ).replace( /'/g, '%27' ).replace( /\(/g, '%28' ).replace( /\)/g, '%29' ).replace( /\*/g, '%2A' ).replace( /\~/g, '%7E' );
}

var PD_pollString2250037 = PDV_html2250037;

function PDV_rand2250037(myArray) {
    var i = myArray.length;
    if (i == 0) return false;
    while (--i) {
        var j = Math.floor(Math.random() * (i + 1));
        var tempi = myArray[i];
        var tempj = myArray[j];
        myArray[i] = tempj;
        myArray[j] = tempi;
    }
    return myArray;
}


function PDV_go2250037()
 {
 	if ( is_secure() ){
 		PDV_def2250037 = PDV_def2250037.replace(/http:\/\/i.polldaddy/g,'https://polldaddy');
 		PDV_def2250037 = PDV_def2250037.replace(/http:\/\/s3.wordpress/g,'https://s-ssl.wordpress');
 	}
    if (!document.getElementById('poll_style2250037')) {
        fileref = document.createElement("style");
        fileref.setAttribute("type", "text/css");
        fileref.setAttribute("id", "poll_style2250037");
        if (fileref.styleSheet) { // IE
            fileref.styleSheet.cssText = PDV_def2250037;
        }
        else { // the world
            fileref.appendChild(document.createTextNode(PDV_def2250037));
        }
        document.getElementsByTagName("head").item(0).appendChild(fileref);
    }
    if (typeof load_audioLibrary_2250037 == "function" && typeof PDV_audio_2250037 !== "undefined" && PDV_audio_2250037 > 0 ) {
    	load_audioLibrary_2250037();
    }
    if (!document.getElementById('PDI_container2250037')) {
        document.write('<a name="pd_a_2250037" style="display: inline; padding: 0px; margin: 0px;"></a><div class="PDS_Poll" id="PDI_container2250037"></div>');
    }    
    if( typeof PDV_version2250037 !== "undefined" ) {
       	PD_ck_name2250037 += ( PDV_version2250037 > 0 ? '.' + PDV_version2250037 : '' );
    }    
    if (Get_Cookie2250037(PD_ck_name2250037) == 'true') {
        PD_ck2250037 = 1;
    }

    document.getElementById('PDI_container2250037').innerHTML = PD_pollString2250037 + '<img src="' + protocol + '//pixel.quantserve.com/pixel/p-ab3gTb8xb3dLg.gif" style="display: none;" border="0" height="1" width="1" alt="Quantcast"/>';

    if (PDV_POLLRAND2250037) {
        AA2250037 = PDV_rand2250037(AA2250037);
    }
    y2250037 = '';
    for (x2250037 = 0; x2250037 < AA2250037.length; x2250037++) {
        y2250037 = y2250037 + AA2250037[x2250037];
    }
    document.getElementById('pds-answer2250037').innerHTML = y2250037;
	share2250037();
}
function Set_Cookie2250037(name, value, expires, path, domain, secure)
 {
    var today = new Date();
    today.setTime(today.getTime());
    if(typeof(PDV_expire2250037) !== 'undefined') {
    	expires = parseInt( PDV_expire2250037 );
    }
    if (expires>0) {
        expires = expires * 1000;
    } else{
    	expires = 60 * 60 * 24 * 30 * 1000;
    }
    
    expires = today.getTime() + (expires);
    var expires_date = new Date(expires);

    document.cookie = name + "=" + escape(expires) +
    ((expires) ? ";expires=" + expires_date.toGMTString() : "") +
    ((path) ? ";path=" + path: "") +
    ((domain) ? ";domain=" + domain: "") +
    ((secure) ? ";secure": "");
}

function Get_Cookie2250037(check_name)
 {
    var a_all_cookies = document.cookie.split(';');
    var a_temp_cookie = '';
    var cookie_name = '';
    var cookie_value = '';
    var b_cookie_found = false;

    for (i = 0; i < a_all_cookies.length; i++)
    {
        a_temp_cookie = a_all_cookies[i].split('=');
        cookie_name = a_temp_cookie[0].replace(/^\s+|\s+$/g, '');
        if (cookie_name == check_name)
        {
            b_cookie_found = true;
            if (a_temp_cookie.length > 1)
       		{
                cookie_value = unescape(a_temp_cookie[1].replace(/^\s+|\s+$/g, ''));
            }
            if( cookie_value == 'true' )
            {
            	return cookie_value;
            }
            else
			{
				var today = new Date();
   			 	cookie_value = parseInt( cookie_value );
   			 	if( cookie_value > today.getTime() )
				{
					return 'true';
				}
			}
            break;
        }
        a_temp_cookie = null;
        cookie_name = '';
    }
    if (!b_cookie_found)
    {
        return null;
    }
}

if (pollClosed2250037 == false) {
    PDV_go2250037();
}


function share2250037()
{
	if( typeof PDV_share2250037 != "undefined") {
		if (PDV_share2250037 == 1 ) {
			a2a_linkname = 'Poll: ' + PDV_POLL_q2250037;
			a2a_linkurl = document.location + '#pd_a_2250037';
			a2a_track_links = 'custom';
			a2a_track_links_key = document.location + '#pd_a_2250037';
			a2a_onclick = 1;
			
	        var s = document.createElement("SCRIPT");
	        s.charset = "utf-8";
	        s.src = protocol + "//static.addtoany.com/menu/page.js";
	        var h = document.getElementsByTagName("head").item(0);
	        h.appendChild(s);
		}
	}
}

function unescape_HTML_2250037(html) {
	var htmlNode = document.createElement("DIV");
	
	htmlNode.innerHTML = html;
	
	if(htmlNode.innerText !== undefined)
		return htmlNode.innerText; // IE
	
	return htmlNode.textContent; // FF
}

if (pollClosed2250037 == true) {
	share2250037();
}

function is_secure() {
	return "https:" == document.location.protocol ? true: false;
}
