var host2 = location.hostname; var imgUrl = (host2=='develop.riro.co.kr') ? '//cdn.riro.co.kr/assets/img' : '//cdn.riroschool.kr/assets/img'; var term=0; var screenHeight=screen.availHeight; var screenWidth=screen.availWidth; var contextMenu=true; var selectStart=true; function bg(obj,col) { obj.style.background=col; } var isMenu=getCookie('cookie_menu'); // ios 13 에서 confirm 동작 문제 발생 ==> 2019.11.22 우회 개발 추가 stony function riroConfirm(text, cb){ var body = document.getElementsByTagName('body')[0]; var overlay = document.createElement('div'); overlay.className = 'confirmWin'; var box = document.createElement('div'); var p = document.createElement('p'); p.appendChild(document.createTextNode(text)); box.appendChild(p); // Create yes and no button var noButton = document.createElement('button'); var yesButton = document.createElement('button'); noButton.appendChild(document.createTextNode('취소')); noButton.addEventListener('click', function(){ cb(false); body.removeChild(overlay); }, false); yesButton.appendChild(document.createTextNode('확인')); yesButton.addEventListener('click', function(){ cb(true); body.removeChild(overlay); }, false); // Append the buttons to the box box.appendChild(noButton); box.appendChild(yesButton); overlay.appendChild(box); body.appendChild(overlay); } function M_openlayer(mouse){ var obj=document.getElementById('left_pannel'); if(isMenu=='closed') { if(mouse=='over'){ obj.style.display='block'; obj.style.backgroundColor ='white'; obj.style.position='absolute'; obj.style.border='1px solid #bbbbbb'; obj.style.marginTop='-20px'; obj.style.zIndex='1000'; obj.style.boxShadow='4px 4px 2px #dddddd'; } else if(mouse=='out'){ obj.style.display='none'; obj.style.backgroundColor=''; obj.style.position='relative'; obj.style.border=''; obj.style.marginTop=''; obj.style.boxShadow=''; } } } function menu_show(device){ var obj=document.getElementById('left_pannel'); var obj2=document.getElementById('main_content'); if(isMenu=='closed') { obj.style.display='block'; if(device=='app'){ obj.style.position='fixed'; obj.style.top='0px'; obj.style.height='100%'; //obj.style.z-index='999'; } else{ obj.style.position='relative'; obj2.style.width='948px'; obj.style.backgroundColor=''; obj.style.border=''; obj.style.marginTop=''; obj.style.boxShadow=''; } isMenu=''; } else { obj.style.display='none'; obj.style.position='absolute'; if(device != 'app') obj2.style.width='1200px'; isMenu='closed'; } saveCookie('cookie_menu', isMenu, 10); } function bgImg(obj,img){ if(img && !obj.value) obj.style.backgroundImage = "url('" + img + "')"; else obj.style.backgroundImage = ''; } function d(d_key) { var d_key=String(d_key); var left=screen.availWidth-410; var dic='http://krdic.naver.com/small_search.nhn?query='; var is_word_test=''; if(!is_word_test){ if(!d_key) var d_key='index'; else { if(d_key.charCodeAt(1)<128){ dic='http://endic.naver.com/popManager.nhn?m=search&query=';} else var d_key=encodeURI(d_key); window.open('board.php?action=dic&club=$club&db=$db&uid=$uid&test_name=$additional_title&key='+d_key,'dic','width=405,height=500,resizable=yes,scrollbars=no,left='+left+', top=30'); } var DICWIN=window.open(dic+d_key,'dic','width=405,height=500,resizable=yes,scrollbars=no,left='+left+', top=30');DICWIN.focus(); } } function error(msg,opt){ if(msg=="login") msg="로그인 후에 이용하세요!!"; else if(msg=="permit") { msg="죄송합니다. 이용권한이 없습니다!"; if(opt) msg=msg+"\n\n이 기능은 '"+opt+"' 이상만 이용할 수 있습니다."; } else if(msg=="password") msg="비밀번호가 일치하지 않습니다!"; else if(msg=="input") { msg="입력할 내용이 다 채워지지 않았습니다!"; if(opt) msg=msg+"\n\n'"+opt+"'를 입력하세요."; } if(msg=="register") { if(confirm("회원으로 등록해야 이용할 수 있습니다.\n지금 등록하시겠습니까?")) mL('reg2',''); } else alert(msg); return false; } function policy(p){ Pwin=window.open('policy.php?p='+p,'policy','width=500,height=350,resizable=yes,scrollbars=yes'); Pwin.focus(); } function mL(type,opt,opt1,opt2,opt3){ var mLstr=mLStr(type,opt,opt1,opt2,opt3); if(mLstr.match('&newwin=new')){ newwin(mLstr); } else if(mLstr.match('&newwin=win')){ win(mLstr); } else if(mLstr.match('&newwin=mod')){ modwin(mLstr); } else if(mLstr.match('&newwin=open')){ window.open(mLstr, 'modwin', 'toolbar=yes'); } else if(mLstr.match('&newwin=stat')){ stat_win(mLstr); } else if(mLstr.match('&newwin=full')){ full_win(mLstr); } else{location.href=mLstr;} } function mLStr(type,opt,opt1,opt2,opt3){ var retStr=''; if(opt1=='undefined') opt1=''; if(type=='reg') retStr='user.php?club='+opt+'&action=register_form'; else if(type=='reg2') retStr='user.php?club='+opt+'&action=register_club'; else if(type=='reg3') retStr='user.php?club='+opt+'&action=unregister_club'; else if(type=='download') retStr='download.php?club='+opt+'&path='+opt1; else if(type=='ftp') retStr='ftp.php?club='+opt+''; else if(type=='mem') retStr='member.php?club='+opt+''; else if(type=='my_list') retStr='stat.php?club='+opt+'&action=my_list'; else if(type=='my_date') retStr='stat.php?club='+opt+'&action=my_date'; else if(type=='my_month') retStr='stat.php?club='+opt+'&action=my_month'; else if(type=='exam') retStr='stat.php?club='+opt+'&action=exam'; else if(type=='admin') retStr='member.php?club='+opt+'&action=list'; else if(type=='qlist') retStr='itempool.php?club='+opt+'&db='+opt1; else if(type=='random') retStr='itempool.php?club='+opt+'&action=random'+'&db='+opt1; else if(type=='idx') retStr='board.php?club='+opt+'&action=all&idx_type='+opt1; else if(type=='list') retStr='board.php?club='+opt+'&action=list&db='+opt1+'&cate='+opt2; else if(type=='send'){ if(opt3) opt3=encodeURIComponent(opt3); retStr='sms.php?club='+opt+'&action='+opt1+'&test='+opt2+'&app_link='+opt3; } else if(type=='meal') { if(opt3) retStr='meal.php?club='+opt+'&action='+opt1+'&db='+opt2+'&uid='+opt3; else retStr='meal.php?club='+opt+'&action='+opt1+'&db='+opt2; } else if(type=='10') retStr='portfolio.php?club='+opt+'&action=idx&db='+opt1; else if(type=='3') retStr='word.php?club='+opt+'&action=list&db='+opt1; else if(type=='4') retStr='portfolio.php?club='+opt+'&action=idx&db='+opt1; else if(type=='5') { if(opt2=='undefined'||!opt2) opt2='list'; if(opt2=='poll') retStr='poll.php?club='+opt+'&db='+opt1+'&action='+opt2+'&cate='+opt3; else if(opt2=='certify') retStr='certify.php?club='+opt+'&db='+opt1+'&action='+opt2+'&act='+opt3; else if(opt2=='bill'||opt2=='apply'||opt2=='certificate'||opt2=='comment'||opt2=='multi_account') retStr='lecture.php?club='+opt+'&db='+opt1+'&action='+opt2+'&cate='+opt3+'&newwin=new'; else if(opt3=='send') retStr='lecture.php?club='+opt+'&db='+opt1+'&action='+opt2+'&cate=send&newwin=new'; else retStr='lecture.php?club='+opt+'&db='+opt1+'&action='+opt2+'&cate='+opt3; } else if(type=='11') { if(opt2=='undefined'||!opt2) opt2='list'; if(opt2=='poll') retStr='poll.php?club='+opt+'&db='+opt1+'&action='+opt2+'&cate='+opt3; else if(opt2=='certify') retStr='certify.php?club='+opt+'&db='+opt1+'&action='+opt2+'&act='+opt3; else if(opt2=='bill'||opt2=='apply'||opt2=='certificate'||opt2=='comment'||opt2=='multi_account') retStr='freesem.php?club='+opt+'&db='+opt1+'&action='+opt2+'&cate='+opt3+'&newwin=new'; else if(opt3=='send') retStr='freesem.php?club='+opt+'&db='+opt1+'&action='+opt2+'&cate=send&newwin=new'; else retStr='freesem.php?club='+opt+'&db='+opt1+'&action='+opt2+'&cate='+opt3; } else if(type=='6') { if(opt2=='undefined'||!opt2) opt2='list'; retStr='record.php?club='+opt+'&db='+opt1+'&action='+opt2+'&cate='+opt3; } else if(type=='7') { if(opt2=='undefined'||!opt2) opt2='list'; retStr='univ.php?club='+opt+'&db='+opt1+'&action='+opt2+'&cate='+opt3; } else if(type=='8') { if(opt2=='undefined'||!opt2) opt2='list'; retStr='photo.php?club='+opt+'&action=list&db='+opt1+'&'+opt2+'='+opt3; } else if(type=='9') { if(opt2=='undefined'||!opt2) opt2='list'; if(opt1>1950&&opt1<=1960) retStr='meal.php?club='+opt+'&action=list&db='+opt1+'&'+opt2+'='+opt3; //else if(opt1.match('1905')) retStr='board.php?club='+opt+'&action=list&db='+opt1; else if(opt1<=1950)retStr='board_msg.php?club='+opt+'&action=list&db='+opt1+'&'+opt2+'='+opt3; else if(opt1>1960)retStr='reserve.php?club='+opt+'&action=list&db='+opt1+'&'+opt2+'='+opt3; } else if(type<3) retStr='board.php?club='+opt+'&action=list&db='+opt1+'&'+opt2+'='+opt3; else if(type=='rank') retStr='stat.php?club='+opt+''; else if(type=='rank2') retStr='stat.php?club='+opt+'&action=view_rank&date='+opt1; else if(type=='my_note') retStr='stat.php?club='+opt+'&action=my_note'; else if(type=='dic') retStr='stat.php?club='+opt+'&action=my_dic'; else if(type=='my_data') retStr='stat.php?club='+opt+'&action=my_data'; else if(type=='cnt') retStr='stat.php?club='+opt+'&action=counter'; else if(type=='logout') retStr='user.php?club='+opt+'&action=logout'; else if(type=='login') retStr='user.php?club='+opt+'&action=login_form'; else if(type=='my_info') retStr='user.php?club='+opt+'&action=modify_form'; else if(type=='lost') retStr='user.php?club='+opt+'&action=lost_pass'; else if(type=='mail') retStr='member.php?action=mailto&address='+opt+'&title='+opt1+'&memo='+opt2+'&newwin=win'; else if(type=='sms') retStr='sms.php?club='+opt+'&action=list&num='+opt1+'&receiver_mode='+opt2+'&newwin=mod'; else if(type=='uni2') retStr='user.php?club='+opt+'&action=union&add_url='+opt; else if(type=='uni') retStr='./'+opt+'&newwin=open'; else if(type=='popup') retStr='board.php?action=view&mode=wide&popup=1&club='+opt+'&db='+opt1+'&uid='+opt2+'&newwin=stat'; else if(type=='stat_all')retStr='board.php?action=stat_all&mode=&popup=1&club='+opt+'&db='+opt1+'&my_id='+opt2+'&newwin=stat'; else if(type=='plan') retStr='univ.php?action=plan&mode=&popup=1&club='+opt+'&db='+opt1+'&my_id='+opt2+'&newwin=full'; else if(type=='skin') retStr='admin.php?club='+opt+'&action=skin_form'; else if(type=='board') retStr='admin.php?club='+opt+'&action=board_form'; else if(type=='edit_board') retStr='admin.php?club='+opt+'&action=db_edit&new_db='+opt1; else if(type=='member') retStr='member.php?club='+opt; else if(type=='counsel') retStr='counsel.php?club='+opt+'&act='+opt1+'&'+opt2+'='+opt3; else if(type=='cumulative') retStr='cumulative.php?club='+opt+'&act='+opt1+'&'+opt2+'='+opt3+'&newwin=stat'; else if(type=='certify') retStr='certify.php?club='+opt+'&act='+opt1+'&'+opt2+'='+opt3; else if(type=='record') { if(!opt1) opt1='list'; if(!opt2) opt2='record'; retStr='record.php?club='+opt+'&action='+opt1+'&db='+opt2+'&mode='+opt3; } else if(type=='board_msg') retStr='board_msg.php?club='+opt+'&action=list&db='+opt1; else if(type=='work') retStr='admin.php?club='+opt+'&action=work&sub=list'; else { retStr=type+'.php?club='+opt+'&action='+opt1+'&act='+opt2+'&db='+opt3; } return retStr; } function sizeDown(obj) { obj.rows += 3; } function sizeUp(obj) { if(obj.rows>3) obj.rows -= 3; } function onA(t){term=t;setMessage();} function setMessage(){ window.status='환영합니다.'; if(term) window.setTimeout(setMessage(),200); } function win(URL){ var WIN2=window.open(URL, 'win', 'toolbar=no, scrollbars=yes, resizable=yes, top=30, width=350, height=300'); WIN2.focus(); } function newwin(URL){ var height=screenHeight - 121; var width=screenWidth - 11; if(width>1920) width=1920; if(URL.match('timetable')) { var num = Math.floor(Math.random() * 1000000); var winname = 'new' + num; } else winname='newwin'; var WIN=window.open(URL, winname, 'toolbar=no,fullscreen=no,scrollbars=yes, resizable=yes, left=0, top=60, width='+width+', height='+height); WIN.focus(); } function modwin(URL){ var WIN3=window.open(URL, 'modwin', 'toolbar=no, scrollbars=yes, resizable=yes, top=60, width=800, height=300'); WIN3.focus(); } function stat_win(URL){ var height=screenHeight - 121; var width=screenWidth - 11; if(width>1920) width=1920; var WIN=window.open(URL, 'stat_win', 'toolbar=no, scrollbars=yes, resizable=yes, left=0, top=60, width='+width+', height='+height); WIN.focus(); } function full_win(URL){ var height=screenHeight - 61; var width=screenWidth - 11; if(width>1920) width=1920; var WIN=window.open(URL, 'full_win', 'toolbar=no, scrollbars=yes, resizable=yes, left=0, top=0, width='+width+', height='+height); WIN.focus(); } function openEditor(obj){ //sel = document.selection.createRange(); if (NS) { sel = document.getSelection(); } else { sel = document.selection.createRange(); } var editWin=window.open('/WebEditor/index.php?object='+obj+'&text=','editor','width=600,height=500,resizable=yes,scrollbars=yes'); editWin.focus(); } function han(obj){ if(obj.style.fontFamily=='한컴돋움') obj.style.fontFamily='굴림'; else obj.style.fontFamily='한컴돋움'; } function editorButton(obj,opt){ if(opt!=2) { document.write("편집기로 입력하기 "); //document.write("옛한글 전환 "); } document.write("글상자 키우기 "); document.write("글상자 줄이기"); } function play(CLUB,DB,MEDIA,OPT1,OPT2,OPT3){ var RS='no'; var WinName='mediawin'; if(OPT3=='wmv') WinName='ment_frame0'; else if(OPT3=='swf'||MEDIA=='R_sound1') RS='yes'; if(!DB) DB='22D6F312'; var URL='board.php?club='+CLUB+'&action=mediaplayer&db='+DB+'&media='+MEDIA+'&opt1='+OPT1+'&opt2='+OPT2+'&db='+DB; var MDWIN=window.open(URL,WinName, 'toolbar=no, scrollbars=no, resizable='+RS+', top=0, width=384, height=225'); MDWIN.focus(); } function sound(CLUB,DB,MEDIA){ hidden.location.href('board.php?club='+CLUB+'&action=soundplayer&mode=hidden&auto_start=1&media='+MEDIA); } function msg(URL){ var MSG=window.open(URL, 'msg', 'toolbar=no, scrollbars=yes, resizable=no, top=30, width=600, height=300'); MSG.focus(); } // 20190715 테이블리스트에서 체크박스 방향 추가 function clickArrow(formAndCheckBoxId, dir, index) { var obj=eval('document.' + formAndCheckBoxId); var bool = !obj[index].checked; if (dir == 'up') { for(var i=index;i>=0;i--){ obj[i].checked = bool } } else if (dir == 'down') { for(var i=index;i<=obj.length-1;i++){ obj[i].checked = bool } } } /* function clickArrow(formAndCheckBoxId, dir, index) { var obj=eval('document.' + formAndCheckBoxId); if(typeof(obj.length) != 'undefined') { var bool = !obj[index].checked if (dir == 'up') { for(var i=index;i>=0;i--){ obj[i].checked = bool } } else if (dir == 'down') { for(var i=index;i<=obj.length-1;i++){ obj[i].checked = bool } } } else { obj.checked = !obj.checked; } } */ function select_all(obj) { var df=document.form1; if( typeof df.elements=='undefined' ) df = df[df.length-1].elements; else df = df.elements; if(!df.num_id.length) df.num_id.checked=obj.checked; else { for(i=0;i18) val*=3; if(fontSize>50) val*=5; } fontSize = fontSize + val; if(fontSize<10) fontSize=10; else if(fontSize>100) fontSize=100; lineHeight = Math.abs(fontSize)+8; if(!eval(name).length) { eval(name).style.fontSize = fontSize + 'px'; eval(name).style.lineHeight = lineHeight + 'px'; } else { for(i=0;i