From 4d16c7c65bdd9833b6e6852c49f029ab003f8e2e Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Fri, 22 Aug 2003 21:35:25 +0000 Subject: Implemented more suggestions by Keith: - Made sure the 'Topic' title is only shown above the topics, not the icons. - Automatically shorten the username when it is too long. I implemented this as part of format_name() and could therefore nuke some code in the statistics module. This is change is somewhat experimental and I'm willing to revert or change this if a number of people aren't too happy with this behavior. - Left align the dates and authors: makes it easier/faster to scan. - Made the little tablesort arrows clickable. --- modules/statistics.module | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'modules/statistics.module') diff --git a/modules/statistics.module b/modules/statistics.module index 8a83afcb9..69948922c 100644 --- a/modules/statistics.module +++ b/modules/statistics.module @@ -637,12 +637,11 @@ function statistics_display_online_block() { if (user_access("access userlist") && $users) { /* Display a list of currently online users */ $max_users = variable_get("statistics_block_online_max_cnt", 10); - $max_name_len = variable_get("statistics_block_online_max_len", 15); $uid = reset($user_list); while (($uid) && ($max_users)) { $user = user_load(array("uid" => $uid)); /* When displaying name, be sure it's not more than defined max length */ - $items[] = l((strlen($user->name) > $max_name_len ? substr($user->name, 0, $max_name_len) ."..." : $user->name), "user/view/$user->uid"); + $items[] = format_name($user); $uid = next($user_list); /* ** When $max_users reaches zero, we break out even if there are -- cgit v1.2.3