posted by 준치 2014. 1. 2. 15:13

좋은 정보를 찾고 드래그 후 복사하고 싶었다..

하지만 다 막아놨다..ㅠㅠ 왜 막아놨는지는 이해는 되나.. 좀 답답했다..

풀수 있는 방법보다는 막는 방법이 더 궁금했다..ㅋㅋ

javascript 로 가능했다. 다음 소스 코드로 하면 된다.

<html>
<head>
<title> New Document </title>
<meta name="Generator" content="EditPlus">
<meta name="Author" content="">
<meta name="Keywords" content="">
<meta name="Description" content="">

<script>

 document.oncontextmenu = function (e) {
  alert("오른쪽버튼 금지");
  return false;
 }

 document.ondragstart = new Function('return false');     // 드래그 금지
 document.onselectstart = new Function('return false');   // 선택 금지

</script>
</head>

<body>
 <div>
  <table>
   <tr>
    <td>가나다라마바사</td>
    <td>가나다라마바사1</td>
   </tr>
  </table>
 </div>
</body>
</html>

출처 : http://www.silverwolf.co.kr/405

오늘도 화이팅!