//------------------ // Copyright 2007 - PollMonkey.com // Publish Date: 8/14/2008 5:26:45 PM //------------------ //--------- Poll Header Functions ------------------------- var cancelSubmit50973 = false; var cancelAlert50973 = false; var secondaryAlert50973 = false; var primaryAlertText50973 = ''; var secondaryAlertText50973 = ''; var col50973 = 1; var NS50973 = (navigator.appName.toLowerCase() == "netscape" && navigator.appVersion.charAt(0)<5) ? true : false; var bUseCaptcha50973 = false; var useDHTML50973 = true; function di2050973(id, newSrc) { document.images[id].src = newSrc; } function preloadImages50973() { if (document.images) { if (typeof(document.WM) == 'undefined'){ document.WM = new Object(); } document.WM.overImages = new Array(); var argLength = preloadImages.arguments.length; for(var arg=0;arg','%3E'); } //-------- END - Poll Header Functions ------------------------------------ //---------- COOKIES FUNCTIONS ------------ function SetCookie50973(name, value, time) { // 1000 milliseconds in a sec var millisecond; millisecond = 1000; time = time * millisecond; // Set expiration of cookie var expDate = new Date(); expDate.setTime(expDate.getTime() + time); document.cookie = name + "=" + escape(value) + ( (expDate) ? ";expires=" + expDate.toGMTString() : ""); } function GetCookie50973(name) { var result = null; var myCookie = " " + document.cookie + ";"; var srchName = " " + name + "="; var start = myCookie.indexOf(srchName); var end; if (start != -1) { start += srchName.length; end = myCookie.indexOf(";", start); result = unescape (myCookie.substring(start, end)); } return result; } function CheckForCookie50973() { check = false; if(GetCookie50973('cookietest') != null) { check = true; } return check; } function CheckCookieExpiration50973() { check = GetCookie50973('50973_VoteFrequency'); if(check != null && check != 99999999) { SetCookie50973('50973_VoteFrequency', '99999999', '99999999'); } } SetCookie50973('cookietest','true', '30'); //---------- END COOKIES FUNCTIONS ------------ //--------- Poll Option Functions ----------------- var a = new Array(); function CheckSelected_50717(useButtons, selectedOptionID, optionID) {if (selectedOptionID == optionID) return " checked "; else return ""; } function SCB50973(i, radioVal, optionID, labelText) {return "" + labelText + ""; } a[0] = SCB50973(0,'620303','620303','No! They should have made them available to the public.'); a[1] = SCB50973(1,'620304','620304','Yes! Church members deserved first chance to buy them'); a[2] = SCB50973(2,'620305','620305','Neither, they should have been free and open to the general public.'); function ClearText_50717() { if (document.Form50973.input_50717_0_1_0_2) document.Form50973.input_50717_0_1_0_2.value = ''; if (document.Form50973.input_50717_0_1_Text_2) document.Form50973.input_50717_0_1_Text_2.value = ''; } function CheckText_50717() { if (document.Form50973.input_50717_0_1_0_2) if (document.Form50973.input_50717_0_1_0_2.value == '') { secondaryAlert50973 = true; secondaryAlertText50973 ='Please enter a response for\nthe choice \'\''; cancelAlert50973 = true; cancelSubmit50973 = true; document.Form50973.input_50717_0_1_0_2.focus(); } if (document.Form50973.input_50717_0_1_Text_2) if (document.Form50973.input_50717_0_1_Text_2.value == '') { secondaryAlert50973 = true; secondaryAlertText50973 ='Please enter a response for\nthe choice \'\''; cancelAlert50973 = true; cancelSubmit50973 = true; document.Form50973.input_50717_0_1_Text_2.focus(); } } function AlertFunction50973(){ cancelSubmit50973 = true; primaryAlertText50973 = "To vote you must select a choice from the poll."; if (document.Form50973.input_50717_0_0_0_2[0].checked) cancelSubmit50973 = false; if (document.Form50973.input_50717_0_0_0_2[1].checked) cancelSubmit50973 = false; if (document.Form50973.input_50717_0_0_0_2[2].checked) cancelSubmit50973 = false; if (cancelSubmit50973 == true || secondaryAlert50973 == true) { alert(primaryAlertText50973 ); return false; } } function GetPollOptions50973(){ var optionselected = ''; if (document.Form50973.input_50717_0_0_0_2[0].checked) optionselected = optionselected + '&input_50717_0_0_0_2=' + document.Form50973.input_50717_0_0_0_2[0].value; if (document.Form50973.input_50717_0_0_0_2[1].checked) optionselected = optionselected + '&input_50717_0_0_0_2=' + document.Form50973.input_50717_0_0_0_2[1].value; if (document.Form50973.input_50717_0_0_0_2[2].checked) optionselected = optionselected + '&input_50717_0_0_0_2=' + document.Form50973.input_50717_0_0_0_2[2].value; return optionselected; } //--------- END - Poll Option Functions ----------------- //--------- Voting Functions ----------------- var browserType50973 = navigator.appName.toLowerCase(); var bDhtml50973 = true; var sVisRes50973 = ' '; function DisplayVote50973() { document.write('
'); CheckCookieExpiration50973(); useDHTML50973 = true; voteFrequency50973 = GetCookie50973('50973_VoteFrequency'); if(voteFrequency50973 == null) { DisplayPoll50973(); } else { PollResponses50973(); } } function Vote50973() { var queryParam; // Check to see if user has selected something if(DoneFunction50973()==false) { return false; } else { SetCookie50973('50973_VoteFrequency', '99999999', '99999999'); //--DYNAMIC SUBMISSION CHECK---- if(bUseCaptcha50973 ==false && bDhtml50973 && totalresponses > 0 && useDHTML50973 ==true) { queryParam = GetPollOptions50973(); queryParam = queryParam + "&returnurl=" + getCurrentURL50973(); queryParam = queryParam + "&qtype_50717=2"; document.getElementById('imgVoteInfo50973').src ='http://www.pollmonkey.com/Pollite/vote.aspx?U=1016550973&UD=39106FAE7A&query=1' + queryParam; PollResponses50973(); } else { document.Form50973.action="http://www.pollmonkey.com/Pollite/vote.aspx?U=1016550973&UD=39106FAE7A"; document.Form50973.submit(); } } } //--------- END - Voting Functions ----------------- function DisplayHeader50973(){ var sHTML = ''; return sHTML; } function DisplayFooter50973(){ var sHTML = ''; sHTML += '
'; return sHTML; } //--------- Begin Writing Display Poll ----------------- function DisplayPoll50973() { var sHTML = ''; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += '
'; sHTML += DisplayHeader50973(); //------Begin Poll Section---- sHTML += '
'; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += '
'; sHTML += '
'; sHTML += ''; sHTML += 'Do you think tickets to the McCain/Obama appearance at Saddleback Church were distributed in a fair manner?'; sHTML += ''; sHTML += ''; sHTML += '
'; // -------Write out the question options------------ sHTML += ''; for (var i = 0; i < a.length; i++) { if(i%col50973==0) { if(i==0) sHTML += ''; else if(i==(a.length-1)) { sHTML += ''; sHTML += ''; } else { sHTML += ''; sHTML += ''; sHTML += ''; } } sHTML += a[i]; } sHTML += '
'; //-------End Poll Questions ------------ sHTML += '
'; if(CheckForCookie50973()) { sHTML += ''; } else { sHTML += 'You must have cookies enabled to vote'; } sHTML += '
'; sHTML += '
'; sHTML += '
'; //------ End Poll Section ---------------------------------- sHTML += DisplayFooter50973(); sHTML += '
'; document.getElementById('pDisp50973').innerHTML = sHTML; } //--------- Begin Writing Poll Responses----------------- function PollResponses50973() { var sHTML = ''; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += '
'; sHTML += DisplayHeader50973(); //-----------Begin Poll Results - RenderPollResults --------- sHTML += ''; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += '
'; sHTML += '
'; sHTML += ''; sHTML += 'Do you think tickets to the McCain/Obama appearance at Saddleback Church were distributed in a fair manner?'; sHTML += ''; sHTML += ''; sHTML += '
'; //----------------------------------- Begin Display Poll Results ------------------------------------- sHTML += ''; var graphcolor = new Array(); graphcolor[0] = new Array('ccccff'); graphcolor[1] = new Array('9999cc'); graphcolor[2] = new Array('666666'); var graphcount=0; for(var i=0; i < options50973.length; i++) { if(graphcount>=graphcolor.length) graphcount=0; if(i%col50973==0) { if(i==0) { sHTML += ''; } else if(i==(options50973.length-1)) { sHTML += ''; } else { sHTML += ''; sHTML += ''; } } sHTML += ''; graphcount++; } sHTML += '
'; sHTML += '' + options50973[i][0] + ''; sHTML += '
'; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += ''; sHTML += '
'; sHTML += '
'; sHTML += '
'; sHTML += '' + options50973[i][1] + '%'; sHTML += '
'; sHTML += '
'; //-------------------------------------- End Display Poll Results ----' //----------------------------------- End Poll Questions ---------------------------------- sHTML += ''; sHTML += '
'; sHTML += 'Total Votes: '+ totalresponses +''; sHTML += '
'; sHTML += ''; sHTML += '
'; //------------- End Poll Section --------------- sHTML += DisplayFooter50973(); sHTML += '
'; document.getElementById('pDisp50973').innerHTML = sHTML; var dResult = document.getElementById('pDisp50973'); dResult.innerHTML = sHTML; var scripts = dResult.getElementsByTagName('script'); for(var i = 0; i < scripts.length; i++) { if(scripts[i].type == 'text/javascript') { eval(scripts[i].innerHTML); } } }