Воскресенье, 10.08.2025, 19:29
Приветствую Вас Гость | RSS
Главная | Защита сайта от копирования - Форум ::NDZ Pub Server CS1.6 | Регистрация | Вход
Форма входа
Поиск
Наш опрос
Как платите за интернет?
Всего ответов: 6
Мини-чат
Друзья сайта
  • Официальный блог
  • Сообщество uCoz
  • FAQ по системе
  • Инструкции для uCoz
  • Статистика
    ::NDZ Pub Server CS1.6
    [ Новые сообщения · Участники · Правила форума · Поиск · RSS ]
    • Страница 1 из 1
    • 1
    Защита сайта от копирования
    NET_DOSTYPAДата: Вторник, 05.08.2008, 16:08 | Сообщение # 1
    Админ в законе
    Администраторы
    Сообщений: 2137
    Репутация: 39
    Offline
    Как мы все знаем, есть куча скриптов "защиты от копирования html страниц", такие как отключение мыши и похожие...
    Данный скрипт устроен совсем по другому.
    При просмотре сайта на котором будет стоять данный скрипт, у юзера, просматривающего сайт, на компьютере будут автоматически отключены PrintScreen и Copy/Past

    Основные функции скрипта это защита!
    - Не даёт копировать содержимое страницы!!!
    - При просмотре сайта отключает функцию копирования!!! (Нельзя ничего копировать пока открыт сайт!)
    - Отключает кнопку PrintScreen!!! (сфотографировать экран не получится!!!) ТОЛЬКО В Internet Explorer 6-7

    Code
    <noscript>    
    <div align=center>

    <img src="http://img99.imageshack.us/img99/2/errortj6.jpg" border="0"></p>    

    <h1>Внимание! В Вашем браузере отключена функция JavaScript!!!</h1>    
    <br>    
    <h2>Пожалуйста включите JavaScript, затем обновите страницу.</h2></p>    
    </div>    
    <style>Table{display:none}</style>    
    </noscript>    

    <SCRIPT LANGUAGE="JavaScript">    

    hp_ok=true;    
    function hp_d01(s)    
    {    
               if(!hp_ok) return; var o="", ar=new Array(), os="", ic=0;    
               for(i=0;i<s.length;i++)    
               {    
                c=s.charCodeAt(i);    
                if(c<128)c=c^2;os+=String.fromCharCode(c);    
                 if(os.length>80){ar[ic++]=os;os=""}    
               }    
               o=ar.join("")+os;    
               document.write(o)    

    }    

    function hp_ne(){return true}    
    onerror=hp_ne;    
    function hp_dn(a){return false}    
    function hp_cm(){return false}    
    function hp_md(e){    
               if(e.which==2||e.which==3){return false}    
               if(e.which==1){window.captureEvents(Event.MOUSEMOVE);window.onmousemove=hp_dn}    
    }    
    function hp_mu(e){    
               if(e.which==1){window.releaseEvents(Event.MOUSEMOVE);window.onmousemove=null}    
    }    
    if(navigator.appName.indexOf('Internet Explorer')==-1||navigator.userAgent.indexOf('MSIE')!=-1){    
               if(document.all){document.oncontextmenu=hp_cm;document.onselectstart=hp_dn}    
               if(document.layers){window.captureEvents(Event.MOUSEUP|Event.MOUSEDOWN);window.onmousedown=hp_md;window.onmouseup=hp_mu}    
               if(document.getElementById&&!document.all){document.oncontextmenu=hp_cm;document.onmousedown=hp_dn}    
    }    
    if(window.location.href.substring(0,4)=="file") window.location="about:blank";    
    function hp_nls(){window.status="";setTimeout("hp_nls()",10)}hp_nls();    
    function hp_dp1(){    
               for(i=0;i<document.all.length;i++){    
                if(document.all[i].style.visibility!="hidden"){    
                 document.all[i].style.visibility="hidden";document.all[i].id="hp_id"}    
                }    
    };    
    function hp_dp2(){    
               for(i=0;i<document.all.length;i++){    
                if(document.all[i].id=="hp_id")document.all[i].style.visibility=""    
               }    
    };    

    window.onbeforeprint=hp_dp1;    
    window.onafterprint=hp_dp2;    

    function hp_dc(){    
               hp_ta.createTextRange().execCommand("Copy");    
               setTimeout("hp_dc()",300)    
    }    

    if(navigator.appName.indexOf('Internet Explorer')==-1||navigator.userAgent.indexOf('MSIE')!=-1){    
               if(document.all&&navigator.userAgent.indexOf('Opera')==-1){    
                document.write('<div style="position:absolute;left:-1000px;top:-1000px"><input type="textarea" name="hp_ta" value=" " style="visibility:hidden"></div>');    
                hp_dc()    
               }    
    }    

    function hp_ndd(){return false}    
    document.ondragstart=hp_ndd;    
    if(navigator.appName.indexOf('Internet Explorer')!=-1&&navigator.userAgent.indexOf('MSIE')==-1) hp_ok=false;    
    if(navigator.userAgent.indexOf('Opera')!=-1)window.location="about:blank";    
    if(frames){    
               if(top.frames.length>0)top.location.href=self.location;    
    }    

    </SCRIPT>


    Если хочешь сказать спасибо жми к репутации
     
    • Страница 1 из 1
    • 1
    Поиск:

    Хостинг от uCozCopyright MyCorp © 2025