Есть простая проблема, но для новичка, я не вижу, в чем проблема. По сути, я пытаюсь отключить кнопку отправки, пока не будет установлен флажок и надпись в форм текста, видела предупреждающие сообщения
CODE ( html):
скопировать код в буфер обмена
<br> <span>Code:</span> <textarea name="code" id="taCode" style="width:100%;height:200px;"></textarea><br/> <input type="button" value=">>" onclick="exec();">
CODE ( javascript):
скопировать код в буфер обмена
function exec(){ //ProgressBar $("#dialog1").dialog({autoOpen:true,modal:true,height:200,width:600, show: 'bounce'}); progress = setInterval(function() { $.get("other.php?"+new Date(), function(data) { $("#progressbar").progressbar({ value: parseInt(data.percent) }); $('#ui-dialog-title-dialog1').text('PROGRESS: '+data.percent+'%'); $('#current').html('Status: '+data.url); },'json'); }, 600); $("#progressbar").progressbar({ value: 0 }); checkBoxs = []; $("input:checkbox:checked").each(function() {checkBoxs.push($(this).val());}); checkBoxs = $.grep(checkBoxs, function(n) { return ( n !== 'on' ); }) code=encodeURIComponent($('#taCode').val()); $.ajax({url:'exer.php', type:'POST', data:'do=exec&code='+code+'&id='+checkBoxs.join(), success:function(result){ $('#ajax').html(result); clearInterval(progress); $('#current').html('Status: Complete!').effect('slide'); } });
|