diff options
| author | Zach DeCook <zachdecook@gmail.com> | 2018-03-20 12:18:58 -0400 |
|---|---|---|
| committer | Zach DeCook <zachdecook@gmail.com> | 2018-03-20 12:19:10 -0400 |
| commit | c48449a69211d1385f477f4c87896491770ce4c6 (patch) | |
| tree | fa9998c6ea31b64007ea5398c0b502db71e5072b /sort.php | |
| parent | 316c95cad96e89afc68d315e9f4fa5b9cf322006 (diff) | |
| download | prosongsa-c48449a69211d1385f477f4c87896491770ce4c6.tar.gz | |
* Table of contents: add title sort
Diffstat (limited to 'sort.php')
| -rw-r--r-- | sort.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sort.php b/sort.php index ab72d49..6e24273 100644 --- a/sort.php +++ b/sort.php @@ -6,6 +6,11 @@ function tocKeysort( $a, $b ){ return ord($aKey[0]) - ord($bKey[0]); } +function tocTitleSort( $a, $b ){ + $aTitle = $a['title']; + $bTitle = $b['title']; + return strcmp( $aTitle, $bTitle ); +} function tocBooksort( $a, $b ){ $bookOrder = array( |
