How to Embed Audio and Play in Web Page

February 28th, 2009

At the first time of starting this blog, I want to paly audio such as music like this in the web page. But I am not very clear how to do it. I would like to thanks SongPower’s help for this firstly.

Actually there is a wordpress plugin audioplayer to add audio palying in a post, but this plugin only support MP3 format. Now we can embed most popular audio into web page not only MP3 format. You can do it using HTML <embed> or <object> element. embed is not a standard HTML and XHTML element, so it’s better to use object element.

If you want the audio files are played by windows media player both in IE and FireFox browser, you should set the type arrtibute as “type = application/x-mplayer2″. For more detail information you can check the source code of my post “丽江纳西民歌“。

相关文章

1 Comment Add your own

Leave a Comment

Required

Required, hidden

Some HTML allowed:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Trackback this post  |  Subscribe to the comments via RSS Feed


订阅

存档

最新文章

最新留言

友情链接

分类

我的豆瓣