How do I insert audio and video into a webpage in html? -Html tutorial

Source: Internet
Author: User
Common multimedia files on webpages include audio files and video files. For online audio and video files, we usually use the embed tag to insert them. Common multimedia files on webpages include audio files and video files. For online audio and video files, we usually use the embed tag to insert them.

Embed Syntax:

 

Example 1: insert an audio file

     Insert audio files    

The browser preview is as follows:

Note:

We can see that the use of the embed label to insert audio files also has a playback interface with several simple functional buttons.

Example 2: Insert a video file

     Insert audio files    

The browser preview is as follows:

Note:

Because the audio and video files are relatively large, we will not provide online testing functions here. However, you can test the code on your computer.

Insert a video using the embed tag. We can also see in the browser that the browser provides a simple operation interface. Embed tags support many video formats, most of which are supported by mainstream formats.

Embedtag supports large video files, such as .mp4,. avi, And. rmvb. If you cannot play a video using the embed tag, it may be because your video format is incorrect or the encoding is incorrect. You can use the format factory to convert the format.

The preceding figure shows how to insert audio and video into webpages in html? For more information, see other related articles in the first PHP community!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.