文档详情

IE与其他浏览器区别(国外英文资料).doc

发布:2017-06-09约2万字共29页下载文档
文本预览下载声明
IE与其他浏览器区别(国外英文资料) The x of ie, y is the reference point for the parent element of the event trigger element (not including the scrolling distance) The pageX of FF, pageY is a reference point for the body element (so it must include rolling distance) The clientX of ie and ff, clientY is a reference point in the upper left corner of the browser (so it certainly doesnt include scrolling distance) Ies offsetX, offsetY and ffs layerX, layerY is a reference point in the upper left corner of the inner circle of an event triggered by an event, and a negative number is likely to occur when there is a border The result of the scrolling distance is the height (or width) of the child elements greater than the height (or width) of the parent element The problem of document.formname.item ( itemName ) is the problem Note: under IE, you can use document.formname.item ( itemName ) or document.formname.elements [ elementName ]; Under Firefox, you can only use document.formname.elements [ elementName ]. Solution: unify the document.formname.elements [ elementName ]. Class object problems Note: under IE, you can use () or [] to obtain collection class objects; In Firefox, you can only use [] to get the collection class object. Solution: use the [] to get the collection class object. Custom property issues Note: under IE, you can use the method to obtain custom properties, or you can use getAttribute () to get custom properties; Under Firefox, you can only use getAttribute () to get custom properties. Solution: unify the custom properties through getAttribute (). Eval ( idName ) problem Note: under IE, you can use eval ( idName ) or getElementById ( idName ) to obtain an HTML object with an id of idName; Firefox can only use getElementById ( idName ) to get an HTML object with an id of idName. Solution: use getElementById ( idName ) to obtain an HTML object with an id of idName. The variable name is the same problem as an HTML object ID Note: under IE, the ID of the HTML object can be
显示全部
相似文档