Weibo share button
This commit is contained in:
+1
-1
@@ -18,7 +18,7 @@ APlayer.prototype.init = function () {
|
||||
+ '<div class="aplayer-music">'
|
||||
+ '<span class="aplayer-title">' + this.option.music.title + '</span>'
|
||||
+ '<span class="aplayer-author"> - ' + this.option.music.author + '</span>'
|
||||
+ '<a href="#" title="分享至微博"><i class="demo-icon icon-weibo"></i></a>'
|
||||
+ '<a href="javascript:void((function(s,d,e,r,l,p,t,z,c){var%20f=\'http://v.t.sina.com.cn/share/share.php?appkey=2992571369\',u=z||d.location,p=[\'&url=\',e(u),\'&title=\',e(t||d.title),\'&source=\',e(r),\'&sourceUrl=\',e(l),\'&content=\',c||\'gb2312\',\'&pic=\',e(p||\'\')].join(\'\');function%20a(){if(!window.open([f,p].join(\'\'),\'mb\',[\'toolbar=0,status=0,resizable=1,width=440,height=430,left=\',(s.width-440)/2,\',top=\',(s.height-430)/2].join(\'\')))u.href=[f,p].join(\'\');};if(/Firefox/.test(navigator.userAgent))setTimeout(a,0);else%20a();})(screen,document,encodeURIComponent,\'\',\'\',\'' + this.option.music.pic + '\',\'' + '#APlayer音乐分享# ' + this.option.music.title + ' - ' + this.option.music.author + ' \',\'\',\'\'));" title="分享至微博"><i class="demo-icon icon-weibo"></i></a>'
|
||||
+ '</div>'
|
||||
+ '<div class="aplayer-controller">'
|
||||
+ '<div class="aplayer-bar-wrap">'
|
||||
|
||||
@@ -31,7 +31,7 @@ The following HTML structure is used for APlayer:
|
||||
<script src="APlayer.js"></script>
|
||||
```
|
||||
|
||||
And this is how the jRating is initialized:
|
||||
And this is how the APlayer is initialized:
|
||||
|
||||
```
|
||||
var ap = new APlayer({
|
||||
@@ -75,7 +75,8 @@ API
|
||||
|
||||
- [x] 播放进度拖拽控制
|
||||
- [x] 音量控制
|
||||
- [ ] 分享到微博
|
||||
- [x] 分享到微博
|
||||
- [ ] 错误处理
|
||||
- [ ] 播放列表
|
||||
- [ ] 歌词展示
|
||||
|
||||
|
||||
+1
-1
@@ -18,7 +18,7 @@
|
||||
title: 'Preparation',
|
||||
author: 'Hans Zimmer/Richard Harvey',
|
||||
url: 'Preparation.mp3',
|
||||
pic: 'Preparation.jpg'
|
||||
pic: 'https://dn-diygod.qbox.me/Preparation.jpg'
|
||||
}
|
||||
});
|
||||
ap.init();
|
||||
|
||||
Reference in New Issue
Block a user