: seccodeVerify)); } function ajaxresponse(objname, data) { var yn = true; var x = new Ajax('XML', objname); x.get('vote.php?do=comment&' + data, function(s){ var obj = $(objname); s = trim(s); if(s.indexOf('succeed') > -1) { if(obj) { obj.style.display = ''; obj.innerHTML = ''; obj.className = "warning"; } } else { if(obj) warning(obj, s); return false; } }); return yn; } function warning(obj, msg) { obj.style.display = ''; obj.innerHTML = '   ' + msg; obj.className = "warning"; } var alreadySelect = 0; function checkSelect(sel, num) { var maxSelect = num; if(sel) { alreadySelect++; if((alreadySelect%num) == 1) { alreadySelect = 1; } if(alreadySelect == maxSelect) { var oObj = document.getElementsByName("option[]"); for(i=0; i < oObj.length; i++) { if(!oObj[i].checked) { oObj[i].disabled = true; } } } } else { alreadySelect--; if(alreadySelect < maxSelect) { var oObj = document.getElementsByName("option[]"); for(i=0; i < oObj.length; i++) { if(oObj[i].disabled) { oObj[i].disabled = false; } } } } } function updde(count, pid){ //Ч²é var optionNum = count; var maxLength = [0,1, 2, 3, 4, 5, 6, 7, 8, 9, 10,11,12,13,14,15,16,17,18,19]; var timer; var length = 0; for(i = 0; i < optionNum; i++) { maxLength[i] = $("bar_" + i + "_" + pid).getAttribute('len'); } timer = setInterval(function(){ setLength(); }, 10); function setLength(){ for (i = 0; i < optionNum; i++) { if (length - 1 >= maxLength[i]) { $('bar_' + i + "_" + pid).style.width = maxLength[i] + "px"; } else { $('bar_' + i + "_" + pid).style.width = length + "px"; } length = length + 1; if (length > 300) { clearInterval(timer); } } } }