Home >Web Front-end >JS Tutorial >Dynamically generated iframe method in javascript compatible with mainstream browsers_javascript skills
The following code runs successfully under IE8 but fails in IE9:
Idea analysis:
Step one: Compatible with IE9, firefox, Opera, Safari and other browsers;
Step 2: Compatible with IE6-8: Because ie6-8 cannot modify the name attribute of the iframe
Comprehensive solution: