diff --git a/lib/ui.lib.php b/lib/ui.lib.php index f3dedfbc..1aff57a6 100644 --- a/lib/ui.lib.php +++ b/lib/ui.lib.php @@ -203,13 +203,6 @@ function show_album_select($name='album', $album_id=0, $allow_add=false, $song_i $key = "album_select_c" . ++$album_id_cnt; } - // Added ID field so we can easily observe this element - echo "\n"; + + if ($allow_none) { + echo "\t\n"; + } while ($r = Dba::fetch_assoc($db_results)) { $selected = ''; @@ -240,6 +241,10 @@ function show_album_select($name='album', $album_id=0, $allow_add=false, $song_i echo "\n"; + if ($count === 0) { + echo "\n"; + } + } // show_album_select /** @@ -257,12 +262,6 @@ function show_artist_select($name='artist', $artist_id=0, $allow_add=false, $son $key = $name . "_select_c" . ++$artist_id_cnt; } - echo "\n"; + + if ($allow_none) { + echo "\t\n"; + } while ($r = Dba::fetch_assoc($db_results)) { $selected = ''; @@ -290,6 +296,10 @@ function show_artist_select($name='artist', $artist_id=0, $allow_add=false, $son echo "\n"; + if ($count === 0) { + echo "\n"; + } + } // show_artist_select /** diff --git a/locale/fr_FR/LC_MESSAGES/messages.mo b/locale/fr_FR/LC_MESSAGES/messages.mo index ebf7ca0a..ad595b73 100644 Binary files a/locale/fr_FR/LC_MESSAGES/messages.mo and b/locale/fr_FR/LC_MESSAGES/messages.mo differ diff --git a/locale/fr_FR/LC_MESSAGES/messages.po b/locale/fr_FR/LC_MESSAGES/messages.po index df0d183e..826bf100 100644 --- a/locale/fr_FR/LC_MESSAGES/messages.po +++ b/locale/fr_FR/LC_MESSAGES/messages.po @@ -989,11 +989,11 @@ msgstr "Erreur: Les fichiers de configuration sont introuvables ou illisible" #: ../../labels.php:53 msgid "Label Added" -msgstr "étiquette Ajouté" +msgstr "Label ajouté" #: ../../labels.php:78 msgid "Label cannot be found." -msgstr "Étiquette ne peut pas être trouvé." +msgstr "Le label ne peut pas être trouvé." #: ../../lib/class/access.class.php:155 ../../lib/class/access.class.php:159 msgid "Invalid IPv4 / IPv6 Address Entered" @@ -1562,7 +1562,7 @@ msgstr "Vidéos personnelles" #: ../../templates/show_edit_artist_row.inc.php:58 #: ../../templates/sidebar_home.inc.php:36 msgid "Labels" -msgstr "Étiquettes d'étiquetage" +msgstr "Labels" #: ../../lib/class/browse.class.php:372 ../../templates/rightbar.inc.php:129 #: ../../templates/show_recently_played.inc.php:162 @@ -2067,11 +2067,11 @@ msgstr "Nom" #: ../../templates/show_labels.inc.php:40 #: ../../templates/show_labels.inc.php:68 msgid "Category" -msgstr "catégorie" +msgstr "Catégorie" #: ../../lib/class/share.class.php:200 msgid "Share edit" -msgstr "Partager modifier" +msgstr "Modifier partage" #: ../../lib/class/share.class.php:341 ../../lib/class/share.class.php:343 #: ../../templates/show_shares.inc.php:23 @@ -2080,7 +2080,7 @@ msgstr "Partager" #: ../../lib/class/share.class.php:351 msgid "Advanced Share" -msgstr "Partager avancée" +msgstr "Partage avancé" #: ../../lib/class/share.class.php:366 msgid "Temporary direct link" @@ -3991,7 +3991,7 @@ msgstr "Objet non valide sélectionnés" #: ../../song.php:34 ../../song.php:48 ../../song.php:50 msgid "Song Deletion" -msgstr "chanson Suppression" +msgstr "Suppression d'une chanson" #: ../../song.php:35 msgid "Are you sure you want to permanently delete this song?" @@ -3999,7 +3999,7 @@ msgstr "Êtes-vous sûr de vouloir supprimer définitivement cette chanson?" #: ../../song.php:48 msgid "Song has been deleted." -msgstr "Chanson a été supprimé." +msgstr "La chanson a été supprimée." #: ../../song.php:50 msgid "Cannot delete this song." @@ -4660,22 +4660,22 @@ msgstr "Créer" #: ../../templates/show_add_label.inc.php:23 msgid "Add Label" -msgstr "Ajouter une étiquette" +msgstr "Ajouter un un label" #: ../../templates/show_add_label.inc.php:37 #: ../../templates/show_edit_label_row.inc.php:34 msgid "Personal" -msgstr "personnel" +msgstr "Personnel" #: ../../templates/show_add_label.inc.php:38 #: ../../templates/show_edit_label_row.inc.php:35 msgid "Association" -msgstr "association" +msgstr "Association" #: ../../templates/show_add_label.inc.php:39 #: ../../templates/show_edit_label_row.inc.php:36 msgid "Company" -msgstr "société" +msgstr "Société" #: ../../templates/show_add_label.inc.php:44 #: ../../templates/show_edit_artist_row.inc.php:41 @@ -6396,19 +6396,19 @@ msgstr "Envoyer un email" #: ../../templates/show_label.inc.php:70 ../../templates/show_label.inc.php:73 #: ../../templates/show_label_row.inc.php:45 msgid "Label edit" -msgstr "étiquette modifier" +msgstr "Edition label" #: ../../templates/show_label.inc.php:74 msgid "Edit Label" -msgstr "Modifier le libellé" +msgstr "Modifier le label" #: ../../templates/show_labels.inc.php:28 msgid "Create a new label" -msgstr "Modifier étiquette" +msgstr "Créer un nouveau label" #: ../../templates/show_labels.inc.php:58 msgid "No label found" -msgstr "No label found" +msgstr "Aucun label trouvé" #: ../../templates/show_live_stream.inc.php:24 msgid "Manage Radio Stations" diff --git a/song.php b/song.php index 6a9c5e4a..902f0057 100644 --- a/song.php +++ b/song.php @@ -43,17 +43,19 @@ switch ($_REQUEST['action']) { $song = new Song($_REQUEST['song_id']); if ($song->id && $song->user_upload > 0) { - if (Access::check('interface','50') || ($libitem->user_upload == $GLOBALS['user']->id && AmpConfig::get('upload_allow_remove'))) { + if (Access::check('interface','50') || ($song->user_upload == $GLOBALS['user']->id && AmpConfig::get('upload_allow_remove'))) { if ($song->remove_from_disk()) { show_confirmation(T_('Song Deletion'), T_('Song has been deleted.'), AmpConfig::get('web_path')); } else { show_confirmation(T_('Song Deletion'), T_('Cannot delete this song.'), AmpConfig::get('web_path')); } } else { + debug_event('song', 'Unauthorized to remove this song.', 1); UI::access_denied(); exit; } } else { + debug_event('song', 'Cannot remove a song that wasn\'t uploaded.', 1); UI::access_denied(); exit; } diff --git a/templates/create_web_player_embedded.inc.php b/templates/create_web_player_embedded.inc.php index cce6fe35..d3c15144 100644 --- a/templates/create_web_player_embedded.inc.php +++ b/templates/create_web_player_embedded.inc.php @@ -47,7 +47,6 @@ if ($_REQUEST['append']) { document.onbeforeunload = null; - if (appendmedia) { } else if (playnext) { diff --git a/templates/show_html5_player_headers.inc.php b/templates/show_html5_player_headers.inc.php index 299c4e7a..e6233716 100644 --- a/templates/show_html5_player_headers.inc.php +++ b/templates/show_html5_player_headers.inc.php @@ -471,7 +471,7 @@ function stopBroadcast() window.parent.onbeforeunload = function (evt) { - if (!$("#jquery_jplayer_1").data("jPlayer").status.paused) { + if (!$("#jquery_jplayer_1").data("jPlayer").status.paused && (document.activeElement === undefined || (document.activeElement.href.indexOf('/batch.php') < 0 && document.activeElement.href.indexOf('/stream.php') < 0))) { var message = ''; if (typeof evt == 'undefined') { evt = window.event;