diff options
author | Antonio Gallo <tonicucoz@gmail.com> | 2011-03-08 00:35:15 +0000 |
---|---|---|
committer | Antonio Gallo <tonicucoz@gmail.com> | 2011-03-08 00:35:15 +0000 |
commit | c6e6d09dba4bb4807e5c6b4f8d23954019c6b38d (patch) | |
tree | 1f76db45c866ba8fe8840b4cea609ca72d375610 /h-source/Application/Include/myFunctions.php | |
parent | 27670aeb2ccd579751bdb15412aab4108597ae87 (diff) |
improved languages.php
Diffstat (limited to 'h-source/Application/Include/myFunctions.php')
-rw-r--r-- | h-source/Application/Include/myFunctions.php | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/h-source/Application/Include/myFunctions.php b/h-source/Application/Include/myFunctions.php index cdb5358..4d01851 100644 --- a/h-source/Application/Include/myFunctions.php +++ b/h-source/Application/Include/myFunctions.php @@ -386,6 +386,24 @@ function gtext($string) return $string; } +function singular($string) +{ + if (isset(Lang::$singular[Lang::$current][$string])) + { + return Lang::$singular[Lang::$current][$string]; + } + return $string; +} + +function plural($string) +{ + if (isset(Lang::$plural[Lang::$current][$string])) + { + return Lang::$plural[Lang::$current][$string]; + } + return $string; +} + //rewrite the vendor name function betterVendor($string) { |