var __jjjj = "http://www.snapsurveys.com/PollLoader/SnapService.aspx"; var __RRRR; var __pollVoted = false; var __aa = "72fd86b7-caf7-4ba2-a0c2-d174897392d7"; var __llll = CheckPreviousResponse(); var __gggg = true; function GetPoll() { var __cccc; __cccc = "?T=POLL"; __cccc += "&PRID=" + escapeURI("fb695ecc-4608-4fb4-91b5-259f592d727a"); __cccc = __jjjj + __cccc; CallServer(__cccc); }; function SnapClick() { var __cccc; __cccc = "?T=SC"; __cccc += "&PRID=" + escapeURI("fb695ecc-4608-4fb4-91b5-259f592d727a"); __cccc = __jjjj + __cccc; CallServer(__cccc); }; function ExpandHtml(html) { html = ReplaceText(html, "_1#", "cellspacing="); html = ReplaceText(html, "_2#", "cellpadding="); html = ReplaceText(html, "_3#", "border-width: 0px; padding:0px; margin:0px;"); html = ReplaceText(html, "_4#", "background-color:"); html = ReplaceText(html, "_5#", " "); html = ReplaceText(html, "_12#", "font-family: Arial, Helvetica, sans-serif"); html = ReplaceText(html, "_13#", "font-family: 'Times New Roman', Times, serif"); return html; }; function ReplaceText(__AAAA, __HHHH, __GGGG) { while (__AAAA.indexOf(__HHHH) != -1) { __AAAA = __AAAA.replace(__HHHH, __GGGG); } return __AAAA; }; function CheckPreviousResponse() { if (document.cookie.length > 0 && document.cookie.indexOf(__aa) >= 0) { return true; } return false; }; function DropCookie() { var __wwww = new Date(); __wwww.setFullYear(__wwww.getFullYear() + 1); var __mmmm = "sid=" + __aa; __mmmm += ';expires=' + __wwww.toGMTString(); document.cookie = __mmmm; }; function Vote(U) { var __nnnn = GetSetting(0); var __kkkk = GetSetting(1); var __tttt = ""; var __cccc; if (__pollVoted == false) { __pollVoted = true; if (!(!__gggg && __llll)) { var __widgetpollVar = GetElement("widgetpoll_1"); if (__widgetpollVar != null && __widgetpollVar.options) { for (var __xxxx = 0; __xxxx < __widgetpollVar.options.length; __xxxx++) { if (__widgetpollVar.options[__xxxx].selected == true && __widgetpollVar.options[__xxxx].value != "") { var __answerId = __widgetpollVar.options[__xxxx].id; var __idNum = __answerId.substring(__answerId.indexOf("_") + 1); __tttt += __idNum + "x"; } } } else { for (var __xxxx = 0; __xxxx < __kkkk; __xxxx++) { if (GetElement("Chk" + __xxxx).checked == true) { __tttt = __tttt + GetElement("Chk" + __xxxx).value + "x"; } } } } else { alert("Thank you, we have already counted your vote."); } //alert(__tttt); if (__tttt.length == 0 && !(!__gggg && __llll)) { if (__widgetpollVar != null) { alert('Please select an answer!'); } else { alert('Please select at least one answer!'); } __pollVoted = false; } else { GetElement("InstructionText").innerHTML = "Loading results..."; GetElement("VoteButton").innerHTML = GetElement("LoadingImageID").outerHTML; GetElement("VoteButton").style.border = "0px"; GetElement("VoteButton").style.backgroundColor = ""; GetElement("VoteButton").style.height = "25px"; GetElement("Answers").style.visibility = 'hidden'; GetElement("LoadingImageID").style.visibility = 'visible'; __cccc = "?T=VOTE"; __cccc += "&PRID=" + escapeURI("fb695ecc-4608-4fb4-91b5-259f592d727a"); __cccc += "&ANS=" + escapeURI(__tttt); __cccc += "&DTE=" + escapeURI(getDate()); __cccc = __jjjj + __cccc; DropCookie(); CallServer(__cccc); } } }; function CallServer(__ZZZZ) { __ZZZZ = __ZZZZ; __RRRR = new JSONscriptRequest(__ZZZZ); __RRRR.__CCCC(); __RRRR.__KKKK(); }; function escapeURI(__ahah) { if (encodeURIComponent) { return encodeURIComponent(__ahah); } if (escape) { return escape(__ahah) } }; function JSONscriptRequest(__BBBB) { this.__BBBB = __BBBB; this.__DDDD = '&noCacheIE=' + (new Date()).getTime(); this.__rrrr = document.getElementsByTagName("head").item(0); this.__QQQQ = 'YJscriptId' + JSONscriptRequest.__FFFF++; }; JSONscriptRequest.__FFFF = 1; JSONscriptRequest.prototype.__CCCC = function() { this.__dddd = document.createElement("script"); this.__dddd.setAttribute("type", "text/javascript"); this.__dddd.setAttribute("src", this.__BBBB + this.__DDDD); this.__dddd.setAttribute("id", this.__QQQQ); }; JSONscriptRequest.prototype.__TTTT = function() { if (this.__dddd != null) { var __OOOO = 0; var __iiii; for (__iiii = 0; __iiii < this.__rrrr.childNodes.length; __iiii++) { if (this.__rrrr.childNodes[__iiii] == this.__dddd) { this.__rrrr.removeChild(this.__dddd); __OOOO = 1; break; } } if (__OOOO == 1) { var __aiai = 1; } else { var __ajajaj = 1; } } }; JSONscriptRequest.prototype.__KKKK = function() { this.__rrrr.appendChild(this.__dddd); }; function ValidateCheck(__aeaeae, __PPPP) { if (!(!__gggg && __llll)) { var __nnnn = GetSetting(0); var __kkkk = GetSetting(1); var __ffff = GetSetting(2); var __eeee = 0; for (var __xxxx = 0; __xxxx < __kkkk; __xxxx++) { if (GetElement("Chk" + __xxxx).checked == true) { __eeee++; } } if (__PPPP == 1) { if (__eeee > 1) { alert('This answer must be the only option selected, please un-select other responses.'); GetElement(__aeaeae).checked = false; } } else { if (__ffff.length > 0) { if (GetElement(__ffff).checked) { alert('The currently selected response is set to be exclusive to all others.'); GetElement(__aeaeae).checked = false; } } if (__eeee > __nnnn) { alert('You can only select ' + __nnnn + ' responses'); GetElement(__aeaeae).checked = false; } } } }; function GetElement(__vvvv) { if (document.getElementById) { return document.getElementById(__vvvv); } else if (document.all) { return document.all[__vvvv]; } else return null; }; function GetSetting(__JJJJ) { var __IIII = GetElement('hdnS').value; if (__IIII.length > 0) { var __LLLL = __IIII.split(','); return __LLLL[__JJJJ]; } else { return ""; } }; function takeYear(__XXXX) { __xxxx = __XXXX.getYear(); var __yyyy = __xxxx % 100; __yyyy += (__yyyy < 38) ? 2000 : 1900; return __yyyy; }; function leadingZero(__adadad) { if (__adadad < 10) __adadad = "0" + __adadad; return __adadad; }; function getDate() { var __oooo = new Date(); var __afafaf = takeYear(__oooo); var __acacac = leadingZero(__oooo.getMonth() + 1); var __agagag = leadingZero(__oooo.getDate()); var __ababab = leadingZero(__oooo.getHours()); var __VVVV = leadingZero(__oooo.getMinutes()); var __YYYY = leadingZero(__oooo.getSeconds()); return __ababab + '_' + __VVVV + '_' + __YYYY + '_' + __agagag + '_' + __acacac + '_' + __afafaf; }; GetPoll();