Clicking on element A to trigger the event of element B will be recognized as element A in IE8
- 2020-03-30 03:51:43
- OfStack
var menuUrl = $(eventSrc).attr("navUrl");
// if (menuUrl == undefined) {//$(eventSrc) compatible with IE8 identifies error, take the first one
// menuUrl = $("#left_menu-small li:first a").attr("navUrl");
// }
var browser = GetIEVersion();
if (browser == "IE8") {//$(eventSrc) compatible with IE8 identifies error, take the first one
menuUrl = $("#left_menu-small li:first a").attr("navUrl");
}
For example: click on the A element to trigger the event of the B element, according to the reason at this time of the event source is the B element, in IE8 will be identified as the A element, in other browsers no problem, there is no good solution, I only in IE8 manually to get the B element