summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--phpfspot.class.php14
1 files changed, 12 insertions, 2 deletions
diff --git a/phpfspot.class.php b/phpfspot.class.php
index b61f516..b3ad278 100644
--- a/phpfspot.class.php
+++ b/phpfspot.class.php
@@ -1951,10 +1951,20 @@ class PHPFSPOT {
return " ORDER BY p.time DESC";
break;
case 'name_asc':
- return " ORDER BY p.name ASC";
+ if($this->dbver < 9) {
+ return " ORDER BY p.name ASC";
+ }
+ else {
+ return " ORDER BY p.uri ASC";
+ }
break;
case 'name_desc':
- return " ORDER BY p.name DESC";
+ if($this->dbver < 9) {
+ return " ORDER BY p.name DESC";
+ }
+ else {
+ return " ORDER BY p.uri DESC";
+ }
break;
}