HTML script to disable text selection in blogger



To disable text selection on blogger, you can use below script in "HTML/ Java Script Gadget"



<!- start disable copy paste -->
<script src='demo-to-prevent-copy-paste-on-blogger_files/googleapis.js'></script>
<script type='text/javascript'>
if(typeof document.onselectstart!="undefined" ) {document.onselectstart=new Function ("return false" ); }
else{document.onmousedown=new Function ("return false" );
document.onmouseup=new Function ("return false"); } </script>
<!-- End disable copy paste --></!->


NOTE: This script will prevent just text selection on blog. To completely remove copy paste option you will have to disable right click also.

No comments:
Write comments

Services

More Services


© 2014 Education Tutorials. Designed by Bloggertheme9
Powered by Blogger.