MP3-jPlayer - Version 1.4.1

Version Description

  • Added a repeat play option on settings page.
  • Fixed text-player buttons css in Opera.
  • Fixed initial-volume setting error where only the slider was being set and not the volume. Thanks to Darkwave for letting me know.
Download this release

Release Info

Developer simon.ward
Plugin Icon 128x128 MP3-jPlayer
Version 1.4.1
Comparing to
See all releases

Code changes from version 1.4.0 to 1.4.1

css/mp3jplayer-text-sidebar.css CHANGED
@@ -118,8 +118,7 @@ div.jp-interface {
118
 
119
  a.jp-play, a.jp-pause, a.jp-stop, a.jp-previous, a.jp-next {
120
  top: 47px;
121
- width:auto;
122
- height:auto;
123
  border: 0;
124
  cursor: default;
125
  border-bottom: none !important;
@@ -127,11 +126,11 @@ div.jp-interface {
127
  font-family: 'trebuchet ms', Arial, sans-serif; }
128
 
129
 
130
- a.jp-play { left: 184px; font-size: 14px; }
131
- a.jp-pause { left: 175px; font-size: 13px; }
132
- a.jp-stop { visibility: hidden; left: 50px; font-size: 14px; }
133
- a.jp-previous { left:108px; font-size: 11px; top: 48px; }
134
- a.jp-next { left:140px; font-size: 11px; top: 48px; }
135
 
136
 
137
  /* other buttons*/
118
 
119
  a.jp-play, a.jp-pause, a.jp-stop, a.jp-previous, a.jp-next {
120
  top: 47px;
121
+
 
122
  border: 0;
123
  cursor: default;
124
  border-bottom: none !important;
126
  font-family: 'trebuchet ms', Arial, sans-serif; }
127
 
128
 
129
+ a.jp-play { left: 184px; font-size: 14px; width:27px; }
130
+ a.jp-pause { left: 175px; font-size: 13px; width:37px; }
131
+ a.jp-stop { visibility: hidden; left: 50px; font-size: 14px; width:26px; }
132
+ a.jp-previous { left:108px; font-size: 11px; top: 48px; width:29px;}
133
+ a.jp-next { left:140px; font-size: 11px; top: 48px; width:30px; }
134
 
135
 
136
  /* other buttons*/
css/mp3jplayer-text.css CHANGED
@@ -124,11 +124,11 @@ div.jp-interface {
124
  font-family: 'trebuchet ms', Arial, sans-serif; }
125
 
126
 
127
- a.jp-play { left: 254px; font-size: 14px; }
128
- a.jp-pause { left: 243px; font-size: 14px; }
129
- a.jp-stop { visibility: hidden; left: 50px; font-size: 14px; }
130
- a.jp-previous { left:178px; font-size: 11px; top: 48px; }
131
- a.jp-next { left:210px; font-size: 11px; top: 48px; }
132
 
133
 
134
  /* other buttons*/
124
  font-family: 'trebuchet ms', Arial, sans-serif; }
125
 
126
 
127
+ a.jp-play { left: 254px; font-size: 14px; width:27px; }
128
+ a.jp-pause { left: 243px; font-size: 14px; width:37px; }
129
+ a.jp-stop { visibility: hidden; left: 50px; font-size: 14px; width:26px; }
130
+ a.jp-previous { left:178px; font-size: 11px; top: 48px; width:29px; }
131
+ a.jp-next { left:210px; font-size: 11px; top: 48px; width:30px; }
132
 
133
 
134
  /* other buttons*/
js/mp3-jplayer.js CHANGED
@@ -1,5 +1,5 @@
1
  <!--
2
- // MP3-jPlayer 1.4.0
3
  // www.sjward.org
4
 
5
  var foxcurrentstate = "open";
@@ -56,6 +56,7 @@ jQuery(document).ready(function(){
56
  playListInit(foxAutoPlay);
57
  },
58
  oggSupport: false,
 
59
  swfPath: foxpathtoswf
60
  })
61
  .jPlayer("onProgressChange", function(loadPercent, playedPercentRelative, playedPercentAbsolute, playedTime, totalTime) {
@@ -114,7 +115,17 @@ jQuery(document).ready(function(){
114
  jpTotalTime.text(jQuery.jPlayer.convertTime(totalTime));
115
  })
116
  .jPlayer("onSoundComplete", function() {
117
- playListNext();
 
 
 
 
 
 
 
 
 
 
118
  });
119
  jQuery("#player_progress_ctrl_bar a").live( "click", function() {
120
  jQuery("#jquery_jplayer").jPlayer("playHead", this.id.substring(3)*(100.0/global_lp));
1
  <!--
2
+ // MP3-jPlayer 1.4.1
3
  // www.sjward.org
4
 
5
  var foxcurrentstate = "open";
56
  playListInit(foxAutoPlay);
57
  },
58
  oggSupport: false,
59
+ volume: foxInitialVolume,
60
  swfPath: foxpathtoswf
61
  })
62
  .jPlayer("onProgressChange", function(loadPercent, playedPercentRelative, playedPercentAbsolute, playedTime, totalTime) {
115
  jpTotalTime.text(jQuery.jPlayer.convertTime(totalTime));
116
  })
117
  .jPlayer("onSoundComplete", function() {
118
+ if ( foxPlaylistRepeat == "true" ) {
119
+ playListNext();
120
+ }
121
+ else {
122
+ if ( playItem+1 != foxPlayList.length ) {
123
+ playListNext();
124
+ }
125
+ else {
126
+ playListConfig(0);
127
+ }
128
+ }
129
  });
130
  jQuery("#player_progress_ctrl_bar a").live( "click", function() {
131
  jQuery("#jquery_jplayer").jPlayer("playHead", this.id.substring(3)*(100.0/global_lp));
mp3jplayer.php CHANGED
@@ -2,7 +2,7 @@
2
  Plugin Name: MP3-jPlayer
3
  Plugin URI: http://sjward.org/jplayer-for-wordpress
4
  Description: A flexible MP3 player with a playlist that can be added to your content or sidebar.
5
- Version: 1.4.0
6
  Author: Simon Ward
7
  Author URI: http://www.sjward.org
8
  License: GPL2
@@ -28,8 +28,8 @@ if ( !class_exists("mp3Fox") )
28
  class mp3Fox
29
  {
30
  // ------------------ //
31
- var $version_of_plugin = "1.4.0"; // Update me! //
32
- var $option_count = 21;
33
  // ------------------ //
34
 
35
  var $iscompat = false;
@@ -941,6 +941,7 @@ if ( !class_exists("mp3Fox") )
941
  echo "var foxAutoPlay =" . $autoplay . ";\n";
942
  echo "var foxInitialVolume =" . $this->theSettings['initial_vol'] . ";\n";
943
  echo "var foxpathtoimages = \"" .$wpinstallpath. "/wp-content/plugins/mp3-jplayer/css/images/\";\n";
 
944
  if ( $count < 2 ) {
945
  echo "var foxShowPlaylist = \"false\";\n";
946
  }
@@ -1192,7 +1193,8 @@ if ( !class_exists("mp3Fox") )
1192
  'custom_stylesheet' => '/wp-content/plugins/mp3-jplayer/css/mp3jplayer-cyanALT.css',
1193
  'give_shortcode_priority' => 'true',
1194
  'echo_debug' => 'false',
1195
- 'add_track_numbering' => 'true' );
 
1196
 
1197
  $theOptions = get_option($this->adminOptionsName);
1198
  if ( !empty($theOptions) ) {
@@ -1311,6 +1313,9 @@ if ( !class_exists("mp3Fox") )
1311
  if (isset($_POST['mp3foxAddTrackNumbers'])) { $theOptions['add_track_numbering'] = $_POST['mp3foxAddTrackNumbers']; }
1312
  else { $theOptions['add_track_numbering'] = "false"; }
1313
 
 
 
 
1314
  update_option($this->adminOptionsName, $theOptions);
1315
 
1316
  ?>
@@ -1334,6 +1339,7 @@ if ( !class_exists("mp3Fox") )
1334
  <h3 style="margin-bottom: 0px;">Player</h3>
1335
  <p style="margin-top: 10px; margin-bottom: 10px;">&nbsp; Initial volume &nbsp; <input type="text" style="text-align:right;" size="2" name="mp3foxVol" value="<?php echo $theOptions['initial_vol']; ?>" /> &nbsp; <span class="description">(0 - 100)</span></p>
1336
  <p style="margin-top: 0px; margin-bottom: 8px;">&nbsp; <input type="checkbox" name="mp3foxAutoplay" value="true" <?php if ($theOptions['auto_play'] == "true") { _e('checked="checked"', "mp3Fox"); }?> /> &nbsp; Autoplay</p>
 
1337
  <p style="margin-top: 0px; margin-bottom: 8px;">&nbsp; <input type="checkbox" name="mp3foxAddTrackNumbers" value="true" <?php if ($theOptions['add_track_numbering'] == "true") { _e('checked="checked"', "mp3Fox"); }?> /> &nbsp; Number the tracks</p>
1338
  <p style="margin-top: 0px; margin-bottom: 8px;">&nbsp; <input type="checkbox" name="mp3foxShowPlaylist" value="true" <?php if ($theOptions['playlist_show'] == "true") { _e('checked="checked"', "mp3Fox"); }?> /> &nbsp; Start with the playlist showing</p>
1339
  <p style="margin-top: 0px; margin-bottom: 8px;">&nbsp; <input type="checkbox" name="mp3foxDownloadMp3" value="true" <?php if ($theOptions['show_downloadmp3'] == "true") { _e('checked="checked"', "mp3Fox"); }?> /> &nbsp; Display a 'Download mp3' link</p>
2
  Plugin Name: MP3-jPlayer
3
  Plugin URI: http://sjward.org/jplayer-for-wordpress
4
  Description: A flexible MP3 player with a playlist that can be added to your content or sidebar.
5
+ Version: 1.4.1
6
  Author: Simon Ward
7
  Author URI: http://www.sjward.org
8
  License: GPL2
28
  class mp3Fox
29
  {
30
  // ------------------ //
31
+ var $version_of_plugin = "1.4.1"; // Update me! //
32
+ var $option_count = 22;
33
  // ------------------ //
34
 
35
  var $iscompat = false;
941
  echo "var foxAutoPlay =" . $autoplay . ";\n";
942
  echo "var foxInitialVolume =" . $this->theSettings['initial_vol'] . ";\n";
943
  echo "var foxpathtoimages = \"" .$wpinstallpath. "/wp-content/plugins/mp3-jplayer/css/images/\";\n";
944
+ echo "var foxPlaylistRepeat = \"" . $this->theSettings['playlist_repeat'] . "\";\n";
945
  if ( $count < 2 ) {
946
  echo "var foxShowPlaylist = \"false\";\n";
947
  }
1193
  'custom_stylesheet' => '/wp-content/plugins/mp3-jplayer/css/mp3jplayer-cyanALT.css',
1194
  'give_shortcode_priority' => 'true',
1195
  'echo_debug' => 'false',
1196
+ 'add_track_numbering' => 'true',
1197
+ 'playlist_repeat' => 'true' );
1198
 
1199
  $theOptions = get_option($this->adminOptionsName);
1200
  if ( !empty($theOptions) ) {
1313
  if (isset($_POST['mp3foxAddTrackNumbers'])) { $theOptions['add_track_numbering'] = $_POST['mp3foxAddTrackNumbers']; }
1314
  else { $theOptions['add_track_numbering'] = "false"; }
1315
 
1316
+ if (isset($_POST['mp3foxPlaylistRepeat'])) { $theOptions['playlist_repeat'] = $_POST['mp3foxPlaylistRepeat']; }
1317
+ else { $theOptions['playlist_repeat'] = "false"; }
1318
+
1319
  update_option($this->adminOptionsName, $theOptions);
1320
 
1321
  ?>
1339
  <h3 style="margin-bottom: 0px;">Player</h3>
1340
  <p style="margin-top: 10px; margin-bottom: 10px;">&nbsp; Initial volume &nbsp; <input type="text" style="text-align:right;" size="2" name="mp3foxVol" value="<?php echo $theOptions['initial_vol']; ?>" /> &nbsp; <span class="description">(0 - 100)</span></p>
1341
  <p style="margin-top: 0px; margin-bottom: 8px;">&nbsp; <input type="checkbox" name="mp3foxAutoplay" value="true" <?php if ($theOptions['auto_play'] == "true") { _e('checked="checked"', "mp3Fox"); }?> /> &nbsp; Autoplay</p>
1342
+ <p style="margin-top: 0px; margin-bottom: 8px;">&nbsp; <input type="checkbox" name="mp3foxPlaylistRepeat" value="true" <?php if ($theOptions['playlist_repeat'] == "true") { _e('checked="checked"', "mp3Fox"); }?> /> &nbsp; Repeat</p>
1343
  <p style="margin-top: 0px; margin-bottom: 8px;">&nbsp; <input type="checkbox" name="mp3foxAddTrackNumbers" value="true" <?php if ($theOptions['add_track_numbering'] == "true") { _e('checked="checked"', "mp3Fox"); }?> /> &nbsp; Number the tracks</p>
1344
  <p style="margin-top: 0px; margin-bottom: 8px;">&nbsp; <input type="checkbox" name="mp3foxShowPlaylist" value="true" <?php if ($theOptions['playlist_show'] == "true") { _e('checked="checked"', "mp3Fox"); }?> /> &nbsp; Start with the playlist showing</p>
1345
  <p style="margin-top: 0px; margin-bottom: 8px;">&nbsp; <input type="checkbox" name="mp3foxDownloadMp3" value="true" <?php if ($theOptions['show_downloadmp3'] == "true") { _e('checked="checked"', "mp3Fox"); }?> /> &nbsp; Display a 'Download mp3' link</p>
readme.txt CHANGED
@@ -5,13 +5,15 @@ Contributors: simon.ward
5
  Tags: mp3, audio, player, music, jplayer, integration, music player, mp3 player, playlist, media, jquery, javascript, plugin, shortcode, widget, widgets, css, posts, page, sidebar
6
  Requires at least: 2.8
7
  Tested up to: 3.0.4
8
- Stable tag: 1.4.0
9
 
10
- An mp3 player for pages and posts, optional widget and shortcode, template tags. HTML 5 / Flash, works on iphone and ipad.
11
 
12
 
13
  == Description ==
14
- New in 1.4.0 -
 
 
15
 
16
  * A sidebar widget
17
  * A text based player style
@@ -37,7 +39,7 @@ Features -
37
  * Optional shortcode and parameters
38
  * A set of template-tags
39
  * Fully CSS styleable
40
- * Integrates Happyworm's jquery.jplayer that can use HTML 5 or Flash as needed.
41
 
42
 
43
  <br />
@@ -213,6 +215,12 @@ Yes if your theme has header/footer widget areas, if it doesn't then you can use
213
 
214
  == Changelog ==
215
 
 
 
 
 
 
 
216
  = 1.4.0 =
217
  * Added a widget.
218
  * Improvements to admin including library and default folder mp3 lists, custom stylesheet setting, and some new options.
5
  Tags: mp3, audio, player, music, jplayer, integration, music player, mp3 player, playlist, media, jquery, javascript, plugin, shortcode, widget, widgets, css, posts, page, sidebar
6
  Requires at least: 2.8
7
  Tested up to: 3.0.4
8
+ Stable tag: 1.4.1
9
 
10
+ An mp3 player for pages and posts, optional widget and shortcode, template tags. HTML5 / Flash, works on iphone and ipad.
11
 
12
 
13
  == Description ==
14
+ Version 1.4.1 makes repeat playing optional from admin, fixes the text-player buttons CSS in Opera, and fixes the initial-volume setting where the slider was being set but not the volume.
15
+
16
+ New since 1.4.0 -
17
 
18
  * A sidebar widget
19
  * A text based player style
39
  * Optional shortcode and parameters
40
  * A set of template-tags
41
  * Fully CSS styleable
42
+ * Integrates Happyworm's jquery.jplayer that can use HTML5 or Flash as needed.
43
 
44
 
45
  <br />
215
 
216
  == Changelog ==
217
 
218
+ = 1.4.1 =
219
+ * Added a repeat play option on settings page.
220
+ * Fixed text-player buttons css in Opera.
221
+ * Fixed initial-volume setting error where only the slider was being set and not the volume. Thanks to Darkwave for letting me know.
222
+
223
+
224
  = 1.4.0 =
225
  * Added a widget.
226
  * Improvements to admin including library and default folder mp3 lists, custom stylesheet setting, and some new options.
screenshot-2.png CHANGED
Binary file