| Line 173... |
Line 173... |
| 173 |
$str.="<span class=\"float-left\">";
|
173 |
$str.="<span class=\"float-left\">";
|
| 174 |
$str.= "<button type=\"button\" class=\"btn btn-outline-dark mt-1 mx-1\" data-toggle=\"modal\" data-target=\"#masterModal" . $cnt . "\" title=\"Album Information\" data-toggle2=\"tooltip\" data-placement=\"bottom\"><i class=\"fas fa-info\"></i></button>";
|
174 |
$str.= "<button type=\"button\" class=\"btn btn-outline-dark mt-1 mx-1\" data-toggle=\"modal\" data-target=\"#masterModal" . $cnt . "\" title=\"Album Information\" data-toggle2=\"tooltip\" data-placement=\"bottom\"><i class=\"fas fa-info\"></i></button>";
|
| 175 |
|
175 |
|
| 176 |
if (isset($master->{'videos'})) {
|
176 |
if (isset($master->{'videos'})) {
|
| 177 |
$str .= "<button type=\"button\" class=\"btn btn-outline-dark mt-1 mx-1 p-1\" data-toggle=\"modal\" data-target=\"#videoModal" . $cnt . "\" title=\"Videos\" data-toggle2=\"tooltip\" data-placement=\"bottom\"><i class=\"fab fa-youtube btn-youtube\"></i></button>";
|
177 |
$str .= "<button type=\"button\" class=\"btn btn-outline-dark mt-1 mx-1 p-1\" data-toggle=\"modal\" data-target=\"#videoModal" . $cnt . "\" title=\"Videos\" data-toggle2=\"tooltip\" data-placement=\"bottom\"><i class=\"fab fa-youtube btn-youtube\"></i></button>";
|
| - |
|
178 |
$str .= "</span>";
|
| 178 |
$str .= "<div id=\"videoModal" . $cnt . "\" class=\"modal\">";
|
179 |
$str .= "<div id=\"videoModal" . $cnt . "\" class=\"modal\">";
|
| 179 |
$str .= "<div class=\"modal-dialog\">";
|
180 |
$str .= "<div class=\"modal-dialog\">";
|
| 180 |
$str .= "<div class=\"modal-content\">";
|
181 |
$str .= "<div class=\"modal-content\">";
|
| 181 |
$str .= "<div class=\"modal-header bg-primary\">";
|
182 |
$str .= "<div class=\"modal-header bg-primary\">";
|
| 182 |
$str .= "<h4 class=\"modal-title mx-auto\">". (string)$master->{'title'} . " by ";
|
183 |
$str .= "<h4 class=\"modal-title mx-auto\">". (string)$master->{'title'} . " by ";
|
| Line 188... |
Line 189... |
| 188 |
$str .= "</h4>";
|
189 |
$str .= "</h4>";
|
| 189 |
$str .= "<button type=\"button\" class=\"close\" data-dismiss=\"modal\"><i class=\"fas fa-window-close btn-dismiss\"></i></button>";
|
190 |
$str .= "<button type=\"button\" class=\"close\" data-dismiss=\"modal\"><i class=\"fas fa-window-close btn-dismiss\"></i></button>";
|
| 190 |
$str .= "</div>";
|
191 |
$str .= "</div>";
|
| 191 |
|
192 |
|
| 192 |
$str .= "<div class=\"modal-body mx-auto\">";
|
193 |
$str .= "<div class=\"modal-body mx-auto\">";
|
| - |
|
194 |
$str .= "<h4>Videos</h4>";
|
| 193 |
$str .= "<dl>";
|
195 |
$str .= "<ul>";
|
| 194 |
|
196 |
|
| 195 |
foreach ($master->{'videos'} as $video) {
|
197 |
foreach ($master->{'videos'} as $video) {
|
| 196 |
$str .= "<dd><a href=\"" . $video->uri . "\" target=\"_blank\" class=\"btn text-left\" role=\"button\"><i class=\"fab fa-youtube btn-youtube\"></i> " . $video->title . " [" . gmdate('H:i:s', $video->duration) . "]</a></dd>";
|
198 |
$str .= "<li><a href=\"" . $video->uri . "\" target=\"_blank\" class=\"btn text-left\" role=\"button\">" . $video->title . " [" . gmdate('H:i:s', $video->duration) . "]</a></li>";
|
| 197 |
// bugbug too many videos don't run embedded
|
199 |
// bugbug too many videos don't run embedded
|
| 198 |
// $videoParam = basename($video->uri);
|
200 |
// $videoParam = basename($video->uri);
|
| 199 |
// $videoIdx = strpos($videoParam, "=") + 1;
|
201 |
// $videoIdx = strpos($videoParam, "=") + 1;
|
| 200 |
// $str .= "<iframe width=\"280\" height=\"158\" src=\"https://www.youtube-nocookie.com/embed/" . substr($videoParam, $videoIdx) . "?rel=0\" allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen></iframe>";
|
202 |
// $str .= "<iframe width=\"280\" height=\"158\" src=\"https://www.youtube-nocookie.com/embed/" . substr($videoParam, $videoIdx) . "?rel=0\" allow=\"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen></iframe>";
|
| 201 |
}
|
203 |
}
|
| 202 |
|
204 |
|
| 203 |
$str .= "</dl>";
|
205 |
$str .= "</ul>";
|
| 204 |
$str .= "</div>";
|
206 |
$str .= "</div>";
|
| 205 |
$str .= "<div class=\"modal-footer justify-content-between\">";
|
207 |
$str .= "<div class=\"modal-footer justify-content-between\">";
|
| 206 |
$str .= "<span class=\"font-weight-lighter small\">Data provided by <a href=\"" . (string)$master->{'uri'} . "\" target=\"_blank\">Discogs</a></span>";
|
208 |
$str .= "<span class=\"font-weight-lighter small\">Data provided by <a href=\"" . (string)$master->{'uri'} . "\" target=\"_blank\">Discogs</a></span>";
|
| 207 |
$str .= "<span class=\"float-right\"><button type=\"button\" class=\"btn btn-danger\" data-dismiss=\"modal\">Close</button></span>";
|
209 |
$str .= "<span class=\"float-right\"><button type=\"button\" class=\"btn btn-danger\" data-dismiss=\"modal\">Close</button></span>";
|
| 208 |
$str .= "</div>";
|
210 |
$str .= "</div>";
|
| 209 |
$str .= "</div>";
|
211 |
$str .= "</div>";
|
| 210 |
$str .= "</div>";
|
212 |
$str .= "</div>";
|
| 211 |
$str .= "</div>";
|
213 |
$str .= "</div>";
|
| - |
|
214 |
} else {
|
| - |
|
215 |
$str .= "</span>";
|
| 212 |
}
|
216 |
}
|
| 213 |
|
217 |
|
| 214 |
$str.="</span>";
|
- |
|
| 215 |
$str.="<span class=\"float-right\">";
|
218 |
$str .= "<span class=\"float-right\">";
|
| 216 |
|
219 |
|
| 217 |
$barcode = "";
|
220 |
$barcode = "";
|
| 218 |
if (empty($_SESSION["barcode"]['Type']) && !empty($master->{'identifiers'})) {
|
221 |
if (empty($_SESSION["barcode"]['Type']) && !empty($master->{'identifiers'})) {
|
| 219 |
foreach ($master->{'identifiers'} as $identifier) {
|
222 |
foreach ($master->{'identifiers'} as $identifier) {
|
| 220 |
if ($identifier->{'type'} == 'Barcode') {
|
223 |
if ($identifier->{'type'} == 'Barcode') {
|