diff options
author | Dries Buytaert <dries@buytaert.net> | 2001-03-01 21:34:09 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2001-03-01 21:34:09 +0000 |
commit | 728249cbc4a7a907bada7a8569d8a3d2052ab308 (patch) | |
tree | 4bde92dfb269451bc6e1bd266dac49d224e76dde /includes/function.inc | |
parent | a925539e8f668653aa0bc2eb199dae614294ec9e (diff) | |
download | brdo-728249cbc4a7a907bada7a8569d8a3d2052ab308.tar.gz brdo-728249cbc4a7a907bada7a8569d8a3d2052ab308.tar.bz2 |
- fixed small translation glitch in format_interval
- added a couple of missing t() functions
- improved the comments module, fixed the score problem Jeroen
reported earlier -> it's slicker but I hope it won't break anything
Diffstat (limited to 'includes/function.inc')
-rw-r--r-- | includes/function.inc | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/includes/function.inc b/includes/function.inc index de5de07e6..0308a5efc 100644 --- a/includes/function.inc +++ b/includes/function.inc @@ -36,19 +36,19 @@ function format_plural($count, $singular, $plural) { function format_interval($timestamp) { if ($timestamp >= 86400) { - $output .= format_plural(floor($timestamp / 86400), "day ", "days "); + $output .= format_plural(floor($timestamp / 86400), "day", "days"); $timestamp = $timestamp % 86400; } if ($timestamp >= 3600) { - $output .= format_plural(floor($timestamp / 3600), "hour ", "hours "); + $output .= " ". format_plural(floor($timestamp / 3600), "hour", "hours"); $timestamp = $timestamp % 3600; } if ($timestamp >= 60) { - $output .= floor($timestamp / 60) ." min "; + $output .= " ". floor($timestamp / 60) ."min"; $timestamp = $timestamp % 60; } if ($timestamp > 0) { - $output .= "$timestamp sec"; + $output .= " $timestamp sec"; } return ($output) ? $output : "0 sec"; } @@ -74,7 +74,6 @@ function format_date($timestamp, $type = "medium") { return $date; } - function format_username($username) { global $user; if ($username) return (user_access($user, "account") ? "<A HREF=\"admin.php?mod=account&op=view&name=$username\">$username</A>" : "<A HREF=\"account.php?op=view&name=$username\">$username</A>"); |