Backend for songs.zachdecook.com
Diffstat (limited to 'sort.php')
-rw-r--r--sort.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/sort.php b/sort.php
index 4048956..f99b60c 100644
--- a/sort.php
+++ b/sort.php
@@ -12,6 +12,12 @@ function tocTitleSort( $a, $b ){
return strcmp( $aTitle, $bTitle );
}
+function tocAuthorSort( $a, $b ){
+ $aTitle = strtolower($a['author']) ?: 'z';
+ $bTitle = strtolower($b['author']) ?: 'z';
+ return strcmp( $aTitle, $bTitle );
+}
+
define( "BOOK_ORDER", array(
'Genesis',
'Exodus',