Home >Web Front-end >Front-end Q&A >How to use html source tag
The
source tag is a new tag in HTML 5; used to define media resources for media elements (such as video and audio). This tag allows you to specify alternative video/audio files for the browser to select based on its media type or codec support.
#How to use the html source tag?
The source tag is a new tag in HTML 5; used to define media resources for media elements (such as video and audio).
Description: The
Note: IE 8 or earlier versions of IE browsers do not support the
html source tag example
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> </head> <body> <audio controls> <source src="https://img.php.cn/ueditor/php/upload/file/20190323/1553324890593240.ogg" > <source src="https://img.php.cn/ueditor/php/upload/file/20190323/1553324890628612.mp3" > 您的浏览器不支持 audio 元素。 </audio> </body> </html>
Rendering:
The above is the detailed content of How to use html source tag. For more information, please follow other related articles on the PHP Chinese website!