갤러리 스킨에서 그림 다운로드 못하게 하려면? 정보
갤러리 스킨에서 그림 다운로드 못하게 하려면?본문
갤러리 게시판에서 리스트에서 오른쪽클릭 금지 테그는 아는데
그림을 클릭하면 원본새창이 뜨잖아요 그 창에서 오른쪽 클릭해서 다운로드 받아버리는데
그거 못하게 하는 소스좀 알려 주십시요
댓글 전체
js/common.js 파일의 273번라인부근에보시면 테이블이 있습니다..
oncontextmenu='return false' onselectstart='return false' ondragstart='return false'
위소스를 넣어주세요...^^
oncontextmenu='return false' onselectstart='return false' ondragstart='return false'
위소스를 넣어주세요...^^
그누보드 3 버젼인데요?
앗...그렇군요....그누4인줄알고 ... 죄송합니다...^^
자바스크립트 파일 찾아보시면 비슷하게 구현되어있지 않을까요?
자바스크립트 파일 찾아보시면 비슷하게 구현되어있지 않을까요?
해당 스킨의 gbview.skin.php의 상단에 스크립트 부분
<script language="JavaScript">
<!--
function image_window2(src)
{
var img = src.src;
var tmp_w = w = src.tmp_width;
var tmp_h = h = src.tmp_height;
winl = (screen.width-w)/2;
wint = (screen.height-h)/3;
if (w >= screen.width) {
winl = 0;
w = screen.width - 10;
h = (parseInt)(w * (h / w));
}
if (h >= screen.height) {
wint = 0;
h = screen.height - 80;
w = (parseInt)(h * (w / h));
}
var settings ='width='+w+',';
settings +='height='+h+',';
settings +='top='+wint+',';
settings +='left='+winl+',';
settings +='scrollbars=no,';
settings +='resizable=no,';
settings +='status=no';
win=window.open("","newWindow",settings);
win.document.open();
win.document.write ("<html><head><meta http-equiv='content-type' content='text/html; charset=euc-kr'>");
win.document.write ("<title>이미지 보기</title></head>");
win.document.write ("<body leftmargin=0 topmargin=0>");
win.document.write ("<img src='"+img+"' width='"+w+"' height='"+h+"'border=0 onclick='window.close();' style='cursor:hand'>");
win.document.write ("</body></html>");
win.document.close();
if(parseInt(navigator.appVersion) >= 4){win.window.focus();}
}
//-->
</script>
에서
win.document.write ("<body leftmargin=0 topmargin=0>"); 를
win.document.write ("<body leftmargin=0 topmargin=0 oncontextmenu='return false' onselectstart='return false' ondragstart='return false'>");
로 바꾸어 보세요~~~~~
<script language="JavaScript">
<!--
function image_window2(src)
{
var img = src.src;
var tmp_w = w = src.tmp_width;
var tmp_h = h = src.tmp_height;
winl = (screen.width-w)/2;
wint = (screen.height-h)/3;
if (w >= screen.width) {
winl = 0;
w = screen.width - 10;
h = (parseInt)(w * (h / w));
}
if (h >= screen.height) {
wint = 0;
h = screen.height - 80;
w = (parseInt)(h * (w / h));
}
var settings ='width='+w+',';
settings +='height='+h+',';
settings +='top='+wint+',';
settings +='left='+winl+',';
settings +='scrollbars=no,';
settings +='resizable=no,';
settings +='status=no';
win=window.open("","newWindow",settings);
win.document.open();
win.document.write ("<html><head><meta http-equiv='content-type' content='text/html; charset=euc-kr'>");
win.document.write ("<title>이미지 보기</title></head>");
win.document.write ("<body leftmargin=0 topmargin=0>");
win.document.write ("<img src='"+img+"' width='"+w+"' height='"+h+"'border=0 onclick='window.close();' style='cursor:hand'>");
win.document.write ("</body></html>");
win.document.close();
if(parseInt(navigator.appVersion) >= 4){win.window.focus();}
}
//-->
</script>
에서
win.document.write ("<body leftmargin=0 topmargin=0>"); 를
win.document.write ("<body leftmargin=0 topmargin=0 oncontextmenu='return false' onselectstart='return false' ondragstart='return false'>");
로 바꾸어 보세요~~~~~
답변 고맙습니다.
그런데 안돼네요 - -;;
그런데 안돼네요 - -;;
리스트에서 새창입니까?......
그렇다면 해당 부분의 소스 좀 올려 주세요~~~
그렇다면 해당 부분의 소스 좀 올려 주세요~~~