From d6ce51e4ce39c143732f69de9a5590428d6e3c6c Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Sat, 10 Feb 2001 11:59:06 +0000 Subject: - added a "search framework" which allows for easy searching (to be continued) - tidyied up some existing code --- includes/function.inc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'includes/function.inc') diff --git a/includes/function.inc b/includes/function.inc index 98a9da53e..c8b027934 100644 --- a/includes/function.inc +++ b/includes/function.inc @@ -76,8 +76,9 @@ function format_data($field, $replacement = "na") { return ($field) ? $field : $replacement; } -function format_username($username, $admin = 0) { - if ($username) return ($admin) ? "$username" : "$username"; +function format_username($username) { + global $user; + if ($username) return (user_permission($user) ? "$username" : "$username"); else { global $anonymous; return $anonymous; } } -- cgit v1.2.3