* depending on the browser locale change the sequence of the
* language chooser.
*/
-void offer_languages(StrBuf *Target, int nArgs, WCTemplateToken *Token, void *Context) {
+void offer_languages(StrBuf *Target, int nArgs, WCTemplateToken *Token, void *Context, int ContextType) {
int i;
#ifndef HAVE_USELOCALE
char *Lang = getenv("LANG");
StrBufAppendBufPlain(Target, _(Token->Params[0]->Start), -1, 0);
}
+
+
+/*
+ * Returns the language currently in use.
+ * This function returns a static string, so don't do anything stupid please.
+ */
+const char *get_selected_language(void) {
+#ifdef ENABLE_NLS
+#ifdef HAVE_USELOCALE
+ return AvailLang[WC->selected_language];
+#else
+ return "en"
+#endif
+#else
+ return "en"
+#endif
+}
+
+