From 086e72d4b101311fde20d26c5e04eb9bace91986 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Sat, 25 Nov 2000 12:56:04 +0000 Subject: - Redid most of account.php and fixed quite some bugs! Check out your new user account stuff and give me some feedback. --- includes/function.inc | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'includes/function.inc') diff --git a/includes/function.inc b/includes/function.inc index 3c3cd3afe..8f9336603 100644 --- a/includes/function.inc +++ b/includes/function.inc @@ -18,6 +18,11 @@ function load_theme() { return new Theme(); } +function discussion_score($comment) { + $value = ($comment->votes) ? ($comment->score / $comment->votes) : (($comment->score) ? $comment->score : 0); + return (strpos($value, ".")) ? substr($value ."00", 0, 4) : $value .".00"; +} + function check_field($message) { return str_replace("\"", """, stripslashes($message)); } -- cgit v1.2.3