GNU5, PHP

GNU4 줄에 색상넣기

페이지 정보

작성자 IN-BEST 댓글 0건 조회 11,379회 작성일 12-05-31 04:06

본문

리스트를 출력시키는 for 구문안에서 for ($i=0; $row=sql_fetch_array($result); $i++) { $list = $i%2; // 짝수면 0 홀수면 1을 출력시킴. echo" 0 || char_max > 0) { check_byte('wr_content', 'char_count'); var cnt = parseInt(document.getElementById('char_count').innerHTML); if (char_min > 0 && char_min > cnt) { alert("댓글은 "+char_min+"글자 이상 쓰셔야 합니다."); return false; } else if (char_max > 0 && char_max < cnt) { alert("댓글은 "+char_max+"글자 이하로 쓰셔야 합니다."); return false; } } else if (!document.getElementById('wr_content').value) { alert("댓글을 입력하여 주십시오."); return false; } if (typeof(f.wr_name) != 'undefined') { f.wr_name.value = f.wr_name.value.replace(pattern, ""); if (f.wr_name.value == '') { alert('이름이 입력되지 않았습니다.'); f.wr_name.focus(); return false; } } if (typeof(f.wr_password) != 'undefined') { f.wr_password.value = f.wr_password.value.replace(pattern, ""); if (f.wr_password.value == '') { alert('비밀번호가 입력되지 않았습니다.'); f.wr_password.focus(); return false; } } if (!chk_captcha()) return false; set_comment_token(f); document.getElementById("btn_submit").disabled = "disabled"; return true; } function comment_box(comment_id, work) { var el_id, form_el = 'fviewcomment', respond = document.getElementById(form_el); // 댓글 아이디가 넘어오면 답변, 수정 if (comment_id) { if (work == 'c') el_id = 'reply_' + comment_id; else el_id = 'edit_' + comment_id; } else el_id = 'bo_vc_w'; if (save_before != el_id) { if (save_before) { document.getElementById(save_before).style.display = 'none'; } document.getElementById(el_id).style.display = ''; document.getElementById(el_id).appendChild(respond); //입력값 초기화 document.getElementById('wr_content').value = ''; // 댓글 수정 if (work == 'cu') { document.getElementById('wr_content').value = document.getElementById('save_comment_' + comment_id).value; if (typeof char_count != 'undefined') check_byte('wr_content', 'char_count'); if (document.getElementById('secret_comment_'+comment_id).value) document.getElementById('wr_secret').checked = true; else document.getElementById('wr_secret').checked = false; } document.getElementById('comment_id').value = comment_id; document.getElementById('w').value = work; if(save_before) $("#captcha_reload").trigger("click"); save_before = el_id; } } function comment_delete() { return confirm("이 댓글을 삭제하시겠습니까?"); } comment_box('', 'c'); // 댓글 입력폼이 보이도록 처리하기위해서 추가 (root님)