projects
/
songbook.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Added Bob's list
[songbook.git]
/
web
/
songbook.php
diff --git
a/web/songbook.php
b/web/songbook.php
index
113af43
..
26917b9
100644
(file)
--- a/
web/songbook.php
+++ b/
web/songbook.php
@@
-1,7
+1,10
@@
<?php
$baseDir = getcwd();
$songDir = "/opt/songbook/Songs";
<?php
$baseDir = getcwd();
$songDir = "/opt/songbook/Songs";
-$debug = $_REQUEST["debug"];
+
+if (isset ($_REQUEST['debug'])) {
+ $debug = $_REQUEST['debug'];
+} // if
// Initialize music objects
$songs = getSongs($songDir);
// Initialize music objects
$songs = getSongs($songDir);
@@
-86,7
+89,7
@@
function setsDropdown () {
} // setsDropdown
function getArtist ($song) {
} // setsDropdown
function getArtist ($song) {
- $lyrics = file_get_contents ($song);
+ $lyrics =
@
file_get_contents ($song);
if (preg_match ("/\{(st|subtitle):(.*)\}/", $lyrics, $matches)) {
return trim ($matches[2]);
if (preg_match ("/\{(st|subtitle):(.*)\}/", $lyrics, $matches)) {
return trim ($matches[2]);