大网数据广告活动
Web 标准与前端开发

loadend

· 52CE 我爱测

loadend 事件总是在一个资源的加载进度停止之后被触发 (例如,在已经触发“error”,“abort”或“load”事件之后)。这适用于 XMLHttpRequest 调用,以及 img 或 video 之类元素的内容。

XMLHttpRequest API

loadend 事件总是在一个资源的加载进度停止之后被触发 (例如,在已经触发“error”,“abort”或“load”事件之后)。这适用于 XMLHttpRequest 调用,以及 img 或 video 之类元素的内容。

General info

  • 规范
  • 接口
    • : ProgressEvent
  • 可冒泡
    • : 否
  • 可取消
    • : 否
  • 触发对象
    • : 例如HTMLImageElement
  • 默认行为
    • : 无

Properties

Property Type Description
target EventTarget The event target (the topmost target in the DOM tree).
type String The type of event.
bubbles Boolean Whether the event normally bubbles or not.
cancelable Boolean Whether the event is cancellable or not.
lengthComputable Boolean Specifies whether or not the total size of the transfer is known. Read only.
loaded unsigned long (long) The number of bytes transferred since the beginning of the operation. This doesn't include headers and other overhead, but only the content itself. Read only.
total unsigned long (long) The total number of bytes of content that will be transferred during the operation. If the total size is unknown, this value is zero. Read only.

规范

参见

  • 相关事件:XMLHttpRequest/loadstart_event、XMLHttpRequest/load_event、XMLHttpRequest/progress_event、XMLHttpRequest/error_event、XMLHttpRequest/abort_event
  • 监测进度

来源:MDN Web Docs / Mozilla 贡献者 · 作者与贡献记录 · CC BY-SA 2.5。离线整理了版式、链接和媒体显示。

资料来源与适用范围

资料来源
MDN Web Docs / Mozilla 贡献者
适用范围
请按文中版本与环境说明核对
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 2.5

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。