Skip to content

Commit

Permalink
Database update + small bugfix
Browse files Browse the repository at this point in the history
  • Loading branch information
olivierberten committed Mar 23, 2013
1 parent bdcb680 commit 7b28c3b
Show file tree
Hide file tree
Showing 3 changed files with 3,102 additions and 3,095 deletions.
4 changes: 2 additions & 2 deletions chant.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
echo "<h4>Sources</h4>\n<ul>\n";
$cnt = 1;
foreach($c_p as $s) {
$source_label = "<i>".$sources[$s[0]]['title'].", ".$sources[$s[0]]['editor'].", ".$sources[$s[0]]['year']."</i>, p. ".$s[1];
$source_label = "<i>".$sources[$s[0]]['title'].", ".$sources[$s[0]]['editor'].", ".$sources[$s[0]]['year']."</i>".($s[1]>''?", p. ".$s[1]:'');
if (count($s) > 2) {
echo '<li><a href="#source_'.$cnt.'">'.$source_label."</a></li>\n";
$sources_img .= '<p><a name="source_'.$cnt.'">'.$source_label."</a><br />\n";
Expand Down Expand Up @@ -109,7 +109,7 @@
} elseif(is_array($content)) {
$gabcs = array();
foreach($content as $e) {
if($e[0] == 'score') $gabcs[] = $e[1];
if($e[0] == 'gabc') $gabcs[] = $e[1];
}
echo "<li>GABC<ul>";
for($i = 0; $i < count($gabcs); $i++) {
Expand Down
2 changes: 1 addition & 1 deletion download.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ function cleanString($string) {
} elseif(is_array($content)) {
$gabcs = array();
foreach($content as $e) {
if($e[0] == 'score') $gabcs[] = $e[1];
if($e[0] == 'gabc') $gabcs[] = $e[1];
}
if(array_key_exists('elem', $_GET) && (int)$_GET['elem'] < count($gabcs)+1) {
$gabc = $gabcs[(int)$_GET['elem']-1];
Expand Down
Loading

0 comments on commit 7b28c3b

Please sign in to comment.