Cited by: http://taoistwar.iteye.com/blog/278963
Today to do a drag effect, find a template on the Internet, after the hair to find a drag will select other parts of the page, need to remove this effect,
Looked for a template to see the following methods: can only be recognized by IE,
Document.onselectstart=function () {return false}
After optimization: (May choose drop-down list frame)
document.onselectstart= function (event) {
if (window.event) {
event = window.event;
}
try {
var the = event.srcelement;
if (! ( (the.tagname== "INPUT" && the.type.toLowerCase () = = "text") | | the.tagname== "TEXTAREA"))
{
return false;
}
return true;
} catch (e) {
return false;
}
}
Then find the style control:
Body
{
-moz-user-focus:ignore;
-moz-user-input:disabled;
-moz-user-select:none;
}
can be compatible with Firefox.
Finally resolved.
Remove HTML selection-compatible with IE, FireFox (document.onselectstart, Style)