Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetDefaultTranslation ¶
SetDefaultTranslation sets the default language to the provided one. Does nothing if it returns error != nil.
Types ¶
type Translation ¶
type Translation struct { Language string Subject string Message string PublishAnnouncement string AnnouncementPublished string PublishedAnnouncements string Login string Logout string Password string CreatedBy string Impressum string PrivacyPolicy string AcceptPrivacyPolicy string History string Back string CaptchaTextBefore string CaptchaTextAfter string DeleteMessages string BotAnswerMessage string BotSendOnThisChannel string BotUserGreetings string RegisterMailRegister string RegisterMailRegisterCaptchaFailure string RegisterMailRegisterNow string RegisterMailRegisterSuccess string RegisterMailValidationSuccess string RegisterMailUnregister string RegisterMailUnregisterSuccessful string RegisterMailRegistrationClosed string RegisterMailEMail string RegisterMailCaptcha string }
Translation represents an object holding all translations
func GetDefaultTranslation ¶
func GetDefaultTranslation() Translation
GetDefaultTranslation returns a Translation struct of the current default language.
func GetTranslation ¶
func GetTranslation(language string) (Translation, error)
GetTranslation returns a Translation struct of the given language. This function always loads translations from disk. Try to use GetDefaultTranslation where possible.
Click to show internal directories.
Click to hide internal directories.