톰캣의 server.xml을 열어서
8080포트 써있는 <>안에
URIEncoding="UTF-8"를 추가 기입한다.
2011년 11월 8일 화요일
2011년 11월 4일 금요일
[Jsp][자바스크립트] CheckBox length undefined
체크박스선택 여부를 판단하려고 하는데,
체크박스 1개일 경우에는 length가 undefined 라고 출력.
우선은 아래처럼 바꿔봤더니 돌아감.
function check_checkBox() {
count = 0;
len = document.fmAdd.chkBig.length;
if (typeof len == "undefined") {
len = 1;
}
if (len == 1) {
if (document.fmAdd.chkBig.checked == true)
return true;
} else {
for ( var i = 0; i < len; i++) {
if (document.fmAdd.chkBig[i].checked == true) {
count++;
}
}
}
if (count == 0)
return false;
if (count > 1) {
alert("ひとつのみ移動可能です。");
return false;
}
}
count = 0;
len = document.fmAdd.chkBig.length;
if (typeof len == "undefined") {
len = 1;
}
if (len == 1) {
if (document.fmAdd.chkBig.checked == true)
return true;
} else {
for ( var i = 0; i < len; i++) {
if (document.fmAdd.chkBig[i].checked == true) {
count++;
}
}
}
if (count == 0)
return false;
if (count > 1) {
alert("ひとつのみ移動可能です。");
return false;
}
}
2011년 11월 2일 수요일
[Jsp][자바스크립트] 최대 크기 팝업 띄우기, 중복 팝업 금지
최대크기로 팝업 열기, 중복 팝업 금지
win="";
function onMaxPop(URL){
if(!win.closed && win){
return;
}
win = window.open("", "", "scrollbars");
win.moveTo(0, 0);
win.resizeTo(screen.availWidth, screen.availHeight);
win.location =URL
}
function onMaxPop(URL){
if(!win.closed && win){
return;
}
win = window.open("", "", "scrollbars");
win.moveTo(0, 0);
win.resizeTo(screen.availWidth, screen.availHeight);
win.location =URL
}
피드 구독하기:
글 (Atom)