Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to use controller in html5

2025-01-30 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/03 Report--

This article mainly shows you "how to use controller in html5", the content is easy to understand, clear, hope to help you solve your doubts, the following let the editor lead you to study and learn "how to use controller in html5" this article.

Example

Detect if the video has a media controller:

MyVid=document.getElementById ("video1"); alert ("Controller:" + myVid.controller)

Definition and usage

The controller property returns the current media controller for audio and video.

By default, audio and video elements do not have a media controller. If a media controller is specified, the controller property returns it as a MediaController.

Browser support

The controller attribute is not supported by any major browser.

Grammar

Audio | video.controller value describes the MediaController object

Represents the media controller for audio and video.

MediaController object properties / methods:

Buffered-get the buffer range of audio and video

Seekable-or the addressable range of audio and video

Duration-the length of time to obtain audio and video

CurrentTime-gets or sets the current playback position of audio and video

Paused-detect if audio and video have been paused

Play ()-play audio and video

Pause ()-pause audio and video

Played-check if audio and video have been played

DefaultPlaybackRate-gets or sets the default playback rate for audio and video

PlaybackRate-gets or sets the current playback rate of audio and video

Volume-gets or sets the volume of audio and video

Muted-gets or sets whether audio and video are muted

Example

Detect if the video has a media controller:

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report