aboutsummaryrefslogtreecommitdiffhomepage
path: root/index.php
diff options
context:
space:
mode:
authorSebastien SAUVAGE <sebsauvage@sebsauvage.net>2013-03-01 17:09:52 +0100
committerSebastien SAUVAGE <sebsauvage@sebsauvage.net>2013-03-01 17:09:52 +0100
commitdd62b9ba2aa93ec867edc14b541da3cd11658679 (patch)
tree360e0c158d56ac8b5e03a95a0ce7ae36c2113bd1 /index.php
parent925f6108ba35ac539457cac282e3159e3fbf6eb2 (diff)
downloadShaarli-dd62b9ba2aa93ec867edc14b541da3cd11658679.tar.gz
Shaarli-dd62b9ba2aa93ec867edc14b541da3cd11658679.tar.zst
Shaarli-dd62b9ba2aa93ec867edc14b541da3cd11658679.zip
Sort tags
Diffstat (limited to 'index.php')
-rw-r--r--index.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/index.php b/index.php
index 3c163154..ee3a0a5c 100644
--- a/index.php
+++ b/index.php
@@ -1109,7 +1109,9 @@ function showDaily()
1109 // We pre-format some fields for proper output. 1109 // We pre-format some fields for proper output.
1110 foreach($linksToDisplay as $key=>$link) 1110 foreach($linksToDisplay as $key=>$link)
1111 { 1111 {
1112 $linksToDisplay[$key]['taglist']=explode(' ',$link['tags']); 1112 $taglist = explode(' ',$link['tags']);
1113 uasort($taglist, 'strcasecmp');
1114 $linksToDisplay[$key]['taglist']=$taglist;
1113 $linksToDisplay[$key]['formatedDescription']=nl2br(keepMultipleSpaces(text2clickable(htmlspecialchars($link['description'])))); 1115 $linksToDisplay[$key]['formatedDescription']=nl2br(keepMultipleSpaces(text2clickable(htmlspecialchars($link['description']))));
1114 $linksToDisplay[$key]['thumbnail'] = thumbnail($link['url']); 1116 $linksToDisplay[$key]['thumbnail'] = thumbnail($link['url']);
1115 } 1117 }
@@ -1761,7 +1763,9 @@ function buildLinkList($PAGE,$LINKSDB)
1761 $classLi = $i%2!=0 ? '' : 'publicLinkHightLight'; 1763 $classLi = $i%2!=0 ? '' : 'publicLinkHightLight';
1762 $link['class'] = ($link['private']==0 ? $classLi : 'private'); 1764 $link['class'] = ($link['private']==0 ? $classLi : 'private');
1763 $link['localdate']=linkdate2locale($link['linkdate']); 1765 $link['localdate']=linkdate2locale($link['linkdate']);
1764 $link['taglist']=explode(' ',$link['tags']); 1766 $taglist = explode(' ',$link['tags']);
1767 uasort($taglist, 'strcasecmp');
1768 $link['taglist']=$taglist;
1765 $linkDisp[$keys[$i]] = $link; 1769 $linkDisp[$keys[$i]] = $link;
1766 $i++; 1770 $i++;
1767 } 1771 }