Loading...

Cara 'disable highlight text' dalam blog korang

Sunday, September 6, 2009

 1.Log in ke dashboard blog korang--> design- ->Page Elements 
2.Klik pada 'Add a Gadget' di sidebar. 
3.Pilih 'HTML/Javascript' kemudian copy kod dibawah ini dan paste dalam ruangan HTML/javascript tadi lalu tekan save.

<script type="text/javascript">

/***********************************************
* Disable select-text script- © Dynamic Drive (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/

//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>

4.Selesai.

0 comments:

Post a Comment