How To Disable Text Selection In Blogger:
copy and paste is increased now a days.so the people doesn't get credit for what they own/create.so in this post i will show you how to disable selection of text in your blogger
go to blogger->select blog
->go to layout
->select add a widget
->select html/javascript
->copy and paste code below and enjoy it
go to blogger->select blog
->go to layout
->select add a widget
->select html/javascript
->copy and paste code below and enjoy it
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
//form tags to omit in NS6+: | |
var omitformtags=["input", "textarea", "select"] | |
omitformtags=omitformtags.join("|") | |
function disableselect(e){ | |
if (omitformtags.indexOf(e.target.tagName.toLowerCase())==-1) | |
return false | |
} | |
function reEnable(){ | |
return true | |
} | |
if (typeof document.onselectstart!="undefined") | |
document.onselectstart=new Function ("return false") | |
else{ | |
document.onmousedown=disableselect | |
document.onmouseup=reEnable | |
} | |
</script> |
No comments:
Write comments