俺的博客左侧的在线Mp3播放器已经用了有段日子了,好像是从2005年的时候就开始用了,Flash的,通过XML文件加载歌曲列表,但是不支持中文歌曲名称,一直想换掉,没抽出空,这几天Google了一阵子,之前这个版本的播放器官网有新版本,下了一个演示版,功能多了不少,歌曲列表也支持中文了,可是变成收费的了。穷人啊,只能继续Google了,找了几款,基本都是收费的,免费版本有功能限制,有的甚至加了商业链接,当然,这也无可厚非。没办法,继续寻找,没想到还找到了,即免费,又开源的一个jPlayer,基于jQuery,加之HTML+CSS控制其样式,总体感觉非常棒,因为可以自己定制样式,我不会编程,所以功能方面的定制就算鸟。于是花了点时间,把播放器的宽度和按钮什么的,能调整的我都调整了,调整到我看着比较舒服,和博客比较搭调的外观,基本没啥问题了,再就是把以前的歌曲里表还得从新弄好,就彻底完工了。
不过,这个jPlayer不是单纯的Mp3播放器哦,在线视频也是可以播放的,暂时不需要视频播放功能,所以就没仔细研究,有需要的同学可以去官方网站详细了解一下。
官方网站:http://www.jplayer.org/
What is jPlayer?
jPlayer is a jQuery plugin that allows you to:
·play and control media files in your webpage
·create and style a media player using just HTML and CSS
·add audio and video to your jQuery projects
·support more devices using HTML5
·support older browsers using a Flash Fallback
·control media on your website using a JavaScript API
jPlayer supports:
·HTML5: mp3, m4a (AAC), m4v (H.264), ogv*, oga*, wav*, webm*
·Flash: mp3, m4a (AAC), m4v (H.264)
* Optional counterpart formats to increase HTML5 x-browser support.
jPlayer works on the latest browsers and the Internet Explorer legacy:
·Windows: Firefox, Chrome, Opera, Safari, IE6, IE7, IE8, IE9 beta
·OSX: Firefox, Chrome, Opera, Safari
·iOS: Mobile Safari: iPad, iPhone, iPod Touch
·Android: We require a device for testing
jPlayer works with jQuery 1.3.2+
About jPlayer
Developed by
Happyworm, jPlayer is Free, Open Source and dual licensed under the
MIT and
GPL licenses.
One of
Mark Boas's many ideas, it has been made real by
Mark Panaghiston.
Silvia Benvenuti helped with the HTML, CSS and all the pretty graphics.
Happyworm is a small web agency that focuses on innovation.
[Edit on 2011-1-30 22:54:58 By 笑傲江湖]