Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

WDS22 - HTML Audio and Something Exciting

In the last article, we learned about embedding YouTube Videos in Html pages which was pretty easy and straightforward. 
After video and images, let's focus on the last element in Media Types that is Audio. Let's see how we can use audios on our web pages to enhance them...

HTML element

To play an audio file in the HTML, we use tag. Let's see by an example...


All the attributes and tags work just like
  • MP3: audio/mpeg
  • Ogg: audio/ogg
  • Wav: audio/wav 
Most of the browsers support the MP3 format, so you should use it as your first preference. Just like video post, I can't show live code example in jsfiddle, so try it in your own web browser with any audio file you have with correct source and type to see the result.
That's all for audio in HTML,
That's all for Media,
That's all for HTML
Yes, we all have learned a lot of HTML in last 22 days. There are some parts of HTML which we can only use when we learn javascript such as using API, drag and drop images in HTML and much more, but what we learned covers more than 95% HTML you will ever need in your life.
From the next article, we are going to see something very interesting and that is no other than CSS. You will actually start loving your web pages. CSS is very simple to understand but very difficult to master, but don't worry we will complete it as simply as we completed our HTML.
That's all for today. Let's meet tomorrow with CSS. Till the #keepCoding.


This post first appeared on The Coding Express, please read the originial post: here

Share the post

WDS22 - HTML Audio and Something Exciting


Subscribe to The Coding Express

Get updates delivered right to your inbox!

Thank you for your subscription