diff --git a/about.php b/about.php
index 7dd2952..80d54eb 100644
--- a/about.php
+++ b/about.php
@@ -136,7 +136,7 @@ function about() {
|
Current version: |
|
- |
+ |
|
@@ -159,7 +159,7 @@ function about() {
|
|
- v1.03 ???? |
+ v1.03 2017.05.02 |
|
@@ -177,6 +177,7 @@ function about() {
- added list of favorite tracks in artist search results
- added possibility to use more than one file name for album cover
- added random play from directory
+ - fixed bugs
|
@@ -320,6 +321,13 @@ function about() {
http://labs.rampinteractive.co.uk/touchSwipe/ |
|
+
+ |
+ Browser |
+ |
+ http://tomicki.net/ |
+ |
+
diff --git a/ajax-random-files.php b/ajax-random-files.php
index c3dc21f..2cde71f 100644
--- a/ajax-random-files.php
+++ b/ajax-random-files.php
@@ -54,7 +54,7 @@
mpd('clear', $player1_host, $player1_port);
foreach ($file as $f) {
- $mpdCommand = mpd ('add "' . str_ireplace($cfg['media_dir'], '', $f) . '"', $player1_host, $player1_port);
+ $mpdCommand = mpd ('add "' . mpdEscapeChar(str_ireplace($cfg['media_dir'], '', $f)) . '"', $player1_host, $player1_port);
if ($mpdCommand == 'ACK_ERROR_NO_EXIST') {
//file not found in MPD database - add stream
playTo(0,'',$f,'',$player1_host, $player1_port);
diff --git a/browser.php b/browser.php
index ff96b79..545a95e 100644
--- a/browser.php
+++ b/browser.php
@@ -49,6 +49,11 @@
// +------------------------------------------------------------------------+
require_once('include/initialize.inc.php');
$cfg['menu'] = 'Library';
+
+// formattedNavigator
+$nav = array();
+$nav['name'][] = 'Browser';
+
authenticate('access_playlist');
require_once('include/header.inc.php');
require_once('include/library.inc.php');
diff --git a/include/config.inc.php b/include/config.inc.php
index 142f26b..f4d820b 100644
--- a/include/config.inc.php
+++ b/include/config.inc.php
@@ -69,6 +69,7 @@
+
// +------------------------------------------------------------------------+
// | Multi-disc indicators |
// +------------------------------------------------------------------------+
@@ -85,65 +86,69 @@
$cfg['multidisk_indicator'][] = " Vol.";
+
+
// +------------------------------------------------------------------------+
-// | Multi-genre separator |
+// | Other versions of album |
// +------------------------------------------------------------------------+
-// | String separating genres and styles in GENRE and STYLE tags |
+// | Show other versions of album in album view |
// +------------------------------------------------------------------------+
-$cfg['multigenre_separator'] = ";";
+$cfg['show_album_versions'] = true;
+
// +------------------------------------------------------------------------+
-// | Use STYLE tag |
+// | Other versions of album indicators |
// +------------------------------------------------------------------------+
-// | Add values from STYLE tag to genres |
+// | Strings in album title indicating that album may have other versions |
+// | e.g. " (" in: |
+// | Brothers In Arms (24bit-96kHz) |
+// | Brothers In Arms (2013 Remaster, MFSL, 24bit-88.2kHz) |
// +------------------------------------------------------------------------+
+unset($cfg['album_versions_indicator']);
+
+$cfg['album_versions_indicator'][] = " (";
+$cfg['album_versions_indicator'][] = " [";
+$cfg['album_versions_indicator'][] = ", ";
-$cfg['style_enable'] = false;
// +------------------------------------------------------------------------+
-// | Other versions of album |
+// | Multi-genre separator |
// +------------------------------------------------------------------------+
-// | Show other versions of album in album view |
+// | String separating genres and styles in GENRE and STYLE tags |
// +------------------------------------------------------------------------+
-$cfg['show_album_versions'] = true;
+$cfg['multigenre_separator'] = "; ";
// +------------------------------------------------------------------------+
-// | Allow access to all files |
+// | Use STYLE tag |
// +------------------------------------------------------------------------+
-// | When set to true, it allows to access to files outside of media |
-// | directory in file browser and for download. |
-// | WARNING! Can be dangerous - it allows to access all files your web |
-// | server has access to - including files with passwords |
-// | USE WITH CARE! |
+// | Add values from STYLE tag to genres |
// +------------------------------------------------------------------------+
-$cfg['allow_access_to_all_files'] = false;
+$cfg['style_enable'] = false;
// +------------------------------------------------------------------------+
-// | Other versions of album indicators |
+// | Allow access to all files |
// +------------------------------------------------------------------------+
-// | Strings in album title indicating that album may have other versions |
-// | e.g. " (" in: |
-// | Brothers In Arms (24bit-96kHz) |
-// | Brothers In Arms (2013 Remaster, MFSL, 24bit-88.2kHz) |
+// | When set to true, it allows to access to files outside of media |
+// | directory in file browser and for download. |
+// | WARNING! Can be dangerous - it allows to access all files your web |
+// | server has access to - including files with passwords |
+// | USE WITH CARE! |
// +------------------------------------------------------------------------+
-unset($cfg['album_versions_indicator']);
-$cfg['album_versions_indicator'][] = " (";
-$cfg['album_versions_indicator'][] = " [";
-$cfg['album_versions_indicator'][] = ", ";
+$cfg['allow_access_to_all_files'] = false;
@@ -163,6 +168,7 @@
+
// +------------------------------------------------------------------------+
// | Timezone Setting |
// +------------------------------------------------------------------------+
@@ -172,21 +178,11 @@
$cfg['timezone'] = '';
-
// +------------------- END OF NEW IN O!MPD 1.03 ---------------------------+
-// +------------------------------------------------------------------------+
-// | Use COMMENT as tags and display it in album view |
-// +------------------------------------------------------------------------+
-
-$cfg['show_comments_as_tags'] = true;
-
-
-
-
// +------------------------------------------------------------------------+
// | MPD password |
// +------------------------------------------------------------------------+
@@ -328,6 +324,15 @@
+// +------------------------------------------------------------------------+
+// | Use COMMENT as tags and display it in album view |
+// +------------------------------------------------------------------------+
+
+$cfg['show_comments_as_tags'] = true;
+
+
+
+
// +------------------------------------------------------------------------+
// | Tag separator |
// +------------------------------------------------------------------------+
@@ -948,12 +953,7 @@
$cfg['offline'] = false;
$cfg['offline_message'] = '[b]This site is temporarily unavailable.[/b][br]We apologize for the inconvenience.';
-// +------------------------------------------------------------------------+
-// | Timezone Setting |
-// +------------------------------------------------------------------------+
-// | Comment out this line to use PHP's default |
-// +------------------------------------------------------------------------+
-$cfg['timezone'] = 'Europe/Warsaw';
+
// +------------------------------------------------------------------------+
// | Debug |
diff --git a/include/header.inc.php b/include/header.inc.php
index f71a371..b752677 100644
--- a/include/header.inc.php
+++ b/include/header.inc.php
@@ -1,7 +1,7 @@
Update[/list]');
+ . '[list][*]Login with admin rights[*]Then select Config > Update all[/list]');
}
}
diff --git a/include/play.inc.php b/include/play.inc.php
index 21c7c75..5c3335b 100644
--- a/include/play.inc.php
+++ b/include/play.inc.php
@@ -519,6 +519,7 @@ function playTo($insPos, $track_id = '', $filepath = '', $dirpath = '', $player_
elseif ($filepath) {
$filepath = str_replace('ompd_ampersand_ompd','&',$filepath);
+ $filepath = str_replace('ompd_plus_ompd','+',$filepath);
$url = NJB_HOME_URL . 'stream.php?action=streamTo&stream_id=-1&filepath=' . urlencode($filepath);
$pos = strpos($filepath,$cfg['media_dir']);
if ($pos !== false) {
diff --git a/index.php b/index.php
index 05e0f2d..95b9863 100644
--- a/index.php
+++ b/index.php
@@ -2404,8 +2404,8 @@ function viewRandomFile() {
$selectedDir = str_replace('"',""",$selectedDir); */
- $selectedDir = isset($_GET['selectedDir']) ? myHTMLencode($_GET['selectedDir']) : $dir;
-
+ $selectedDir = isset($_GET['selectedDir']) ? myHTMLencode($_GET['selectedDir']) : myHTMLencode($dir);
+
require_once('include/header.inc.php');
?>
diff --git a/play.php b/play.php
index d5710a6..8ac5e58 100644
--- a/play.php
+++ b/play.php
@@ -535,6 +535,7 @@ function addTracks($mode = 'play', $insPos = '', $playAfterInsert = '') {
$first = true;
if ($filepath){
$filepath = str_replace('ompd_ampersand_ompd','&',$filepath);
+ $filepath = str_replace('ompd_plus_ompd','+',$filepath);
//$filepath = str_replace('"','\"',$filepath);
$mpdCommand = mpd('addid "' . mpdEscapeChar($filepath) . '" ' . $insPos);
if ($mpdCommand == 'ACK_ERROR_NO_EXIST') {
@@ -551,10 +552,12 @@ function addTracks($mode = 'play', $insPos = '', $playAfterInsert = '') {
}
elseif ($dirpath){
$dirpath = str_replace('ompd_ampersand_ompd','&',$dirpath);
+ $dirpath = str_replace('ompd_plus_ompd','+',$dirpath);
$mpdCommand = mpd('add "' . mpdEscapeChar($dirpath) . '"');
if ($mpdCommand == 'ACK_ERROR_NO_EXIST') {
//dir not found in MPD database - add stream
$fulldirpath = str_replace('ompd_ampersand_ompd','&',$fulldirpath);
+ $fulldirpath = str_replace('ompd_plus_ompd','+',$fulldirpath);
$mediafiles = find_all_files($fulldirpath);
foreach($mediafiles as $val) {
playTo($insPos,'',$val);
@@ -1488,13 +1491,22 @@ function playlistTrack() {
$audio = explode(':',$status['audio']);
$data['isStream'] = 'false';
- if (strpos($currentsong['file'],"://") !== false) $data['isStream'] = (string) 'true';
-
+ if (strpos($currentsong['file'],"://") !== false) {
+ $data['isStream'] = (string) 'true';
+ if (strpos($currentsong['file'],'filepath=') !== false){
+ $pos = strpos($currentsong['file'],'filepath=');
+ $filepath = substr($currentsong['file'],$pos + 9, strlen($currentsong['file']) - $pos);
+ $filepath = urldecode($filepath);
+ $relative_file = urlencode(dirname($filepath));
+ }
+ }
+
/* if (isset($currentsong['Artist']))
$artist = $currentsong['Artist'];
else
$$artist = $currentsong['file'];
*/
+
if (isset($currentsong['Name'])) {
$album = $currentsong['Name'];
}
@@ -1502,9 +1514,7 @@ function playlistTrack() {
$album = $currentsong['Album'];
}
elseif (strpos($currentsong['file'],'filepath=') !== false){
- $pos = strpos($currentsong['file'],'filepath=');
- $filepath = substr($currentsong['file'],$pos + 9, strlen($currentsong['file']) - $pos);
- $filepath = urldecode($filepath);
+
$title = basename($filepath);
$pos = strpos($filepath, $title);
$album = substr($filepath, 0, $pos);
@@ -1558,7 +1568,7 @@ function playlistTrack() {
$data['other_track_version'] = (boolean) false;
$data['comment'] = (string) '';
$data['track_id'] = (string) '';
- $data['relative_file'] = (string) '';
+ $data['relative_file'] = (string) $relative_file;
$data['inFavorite'] = (boolean) '';
$data['onBlacklist'] = (boolean) '';
$data['dr'] = (string) '';
diff --git a/playlist.php b/playlist.php
index cb399eb..94a29be 100644
--- a/playlist.php
+++ b/playlist.php
@@ -543,11 +543,11 @@ function evaluateStatus(data) {
$("#trackOptions").hide();
$('#saveCurrentPlaylist i').removeClass("fa-circle-o fa-check-circle-o").addClass("fa-check-circle-o");
$('#saveCurrentTrack i').removeClass("fa-check-circle-o fa-circle-o").addClass("fa-circle-o");
- if (data.isStream == 'true') {
+ /* if (data.isStream == 'true') {
$('#lyrics').html(' ');
$('#lyrics1').html(' ');
$('#fileInfoForDbTracks').css('visibility', 'hidden');
- }
+ } */
}
else {
$("#saveCurrentTrack").show();
@@ -799,7 +799,12 @@ function evaluateTrack(data) {
previous_track_id = data.track_id;
}
-
+ if (data.isStream == 'true' && (!data.genre || !data.year)) {
+ $('#lyrics').html(' ');
+ $('#lyrics1').html(' ');
+ $('#fileInfoForDbTracks').css('visibility', 'hidden');
+ }
+
$("#cover-spinner").show();
var s = Math.floor(data.miliseconds / 1000);
var m = Math.floor(s / 60);
@@ -834,6 +839,11 @@ function evaluateTrack(data) {
document.getElementById('album1').innerHTML = (data.album == ' ') ? ' ' : 'from ' + albumLink;
document.getElementById('album').innerHTML = albumLink;
}
+ else if (data.relative_file) {
+ var albumLink = '' + data.album + '';
+ document.getElementById('album1').innerHTML = (data.album == ' ') ? ' ' : 'from ' + albumLink;
+ document.getElementById('album').innerHTML = albumLink;
+ }
else {
document.getElementById('album1').innerHTML = (data.album == ' ') ? ' ' : 'from ' + data.album;
document.getElementById('album').innerHTML = (data.album == ' ') ? ' ' : data.album;
diff --git a/skin/ompd_the_first/styles.css b/skin/ompd_the_first/styles.css
index cb5b7b7..5690c65 100644
--- a/skin/ompd_the_first/styles.css
+++ b/skin/ompd_the_first/styles.css
@@ -1250,6 +1250,16 @@ tr.even {
transition: all 300ms linear;
}
+tr.artist_list {
+ height: 2.5em;
+ background-color: white;
+}
+
+tr.artist_list td {
+ border-bottom: dotted 1px #E3E3E3;
+}
+
+
tr.year {
height: 2em;
background-color: white;
@@ -2196,10 +2206,10 @@ iframe.full {
width: 100%;
overflow: hidden;
position: relative;
- padding: 0 0 0 2.95em;
- border: 1px solid #dedede;
-
-
+ padding: 0 0 0 2.8em;
+ border-left: 5px solid #e74c3c;
+ border-bottom: 1px solid #dedede;
+ border-right: 1px solid #dedede;
border-top: 0px;
}
diff --git a/statistics.php b/statistics.php
index 5ed8086..e060a3a 100644
--- a/statistics.php
+++ b/statistics.php
@@ -122,7 +122,7 @@
}
}
elseif ($action == 'noImageFront') {
- $title = 'No ' . $cfg['image_front'] . '.jpg/png file';
+ $title = 'No image_front file';
//$onmouseoverImage = false;
$query = mysqli_query($db,'SELECT album.artist_alphabetic, album.album, album.album_id
FROM album, bitmap
@@ -131,7 +131,7 @@
ORDER BY album.artist_alphabetic, album.album');
}
elseif ($action == 'imageError') {
- $title = '' . $cfg['image_front'] . '.jpg/png error';
+ $title = 'image_front file error';
//$onmouseoverImage = false;
$query = mysqli_query($db,'SELECT album.artist_alphabetic, album.album, album.album_id
FROM album, bitmap
@@ -140,7 +140,7 @@
ORDER BY album.artist_alphabetic, album.album');
}
elseif ($action == 'noImageFrontCover') {
- $title = $cfg['image_front'] . '.jpg/png file has less then ' . $cfg['image_front_cover_treshold'] . 'px';
+ $title = 'image_front file has less then ' . $cfg['image_front_cover_treshold'] . 'px';
//$onmouseoverImage = false;
$query = mysqli_query($db,'SELECT album.artist_alphabetic, album.album, album.album_id, album.image_id
FROM album, bitmap
@@ -585,7 +585,7 @@ function mediaStatistics() {
if ($no_image_front > 0) { ?>
|
- : |
+ No image_front file: |
|
|
|
@@ -595,7 +595,7 @@ function mediaStatistics() {
if ($no_image_front_cover > 0) { ?>
|
- for cover: |
+ image_front file has less then px: |
|
|
|