![](/img/trans.png)
[英]What html tags support the onload/onerror javascript event attributes?
[英]What html tags support the onload javascript event?
我知道img
body
和iframe
允许你将onload=
添加到标签并且必须执行。 还有哪些标签支持onload
操作? 您知道所有标签的列表以及支持的操作吗?
html4的规范只提到了body
和frameset
: http : //www.w3.org/TR/html4/interact/scripts.html#h-18.2.3
我认为这取决于浏览器。
你也可以在<script>
标签上使用它,除了你需要onreadystatechange
以获得相同效果的IE。
我认为它也适用于某些浏览器中的<object>
元素(但只是少数)。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.