[ticket/12143] Created a universal function for groupname

If groupname is a var in user->lang starting with G_ then
the translationstring is used, otherwise the name is used.

PHPBB3-12143
[ticket/12143] Rename function and move it to functions_content

And I fixed the things nickvergessen mentioned

PHPBB3-12143