diff options
Diffstat (limited to 'includes/tablesort.inc')
-rw-r--r-- | includes/tablesort.inc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/includes/tablesort.inc b/includes/tablesort.inc index 2e16d8a8d..44a0db948 100644 --- a/includes/tablesort.inc +++ b/includes/tablesort.inc @@ -35,6 +35,9 @@ function tablesort($cell, $header) { $image = " <img border=\"0\" src=\"". theme("image", "arrow-". $ts["sort"]. ".gif"). "\"></img>"; $dir = array("asc" => "ascending", "desc" => "descending"); $title = t("sort ". $dir[$ts["sort"]]); + } else { + // If the user clicks a different header, we want to sort ascending initially. + $ts["sort"] = "asc"; } $cell["data"] = l($cell["data"] . $image, $_GET["q"], array("title" => $title), "sort=". $ts["sort"]. "&order=". urlencode($cell["data"]). $ts["query_string"]); |