Difference between revisions of "User:Trias/spiralknights.js"

From SpiralKnights

Jump to: navigation, search
(Created page with 'window.killEvt = function( evt ) { window.alert("event should cancel"); evt = evt || window.event || window.Event; // W3C, IE, Netscape if ( typeof ( evt.preventDefault…')
 
(clear)
 
Line 1: Line 1:
window.killEvt = function( evt ) {
+
 
        window.alert("event should cancel");
+
evt = evt || window.event || window.Event; // W3C, IE, Netscape
+
if ( typeof ( evt.preventDefault ) != 'undefined' ) {
+
evt.preventDefault(); // Don't follow the link
+
evt.stopPropagation();
+
} else {
+
evt.cancelBubble = true; // IE
+
}
+
return false; // Don't follow the link (IE)
+
}
+

Latest revision as of 09:42, 24 August 2011


Personal tools