Skip to content

Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance

make error msg part of html (allowing translation) instead of hardcoded text

reger290ca9e91494
diff --git a/htroot/Translator_p.html b/htroot/Translator_p.html
index 131af2999..f37527bea 100644
--- a/htroot/Translator_p.html
+++ b/htroot/Translator_p.html
@@ -17,7 +17,7 @@
<legend>
<label>UI Translation</label>
</legend>
- <p>Target Language: <b>#[targetlang]#</b></p><p class="error">#[errmsg]#</p>
+ <p>Target Language: <b>#[targetlang]#</b></p> #(errmsg)#::<p class="error">activate a different language <a href='ConfigBasic.html'>here</a></p>#(/errmsg)#
<label for="sourcefile">Source File</label>
<select name="sourcefile" onchange="submit();">
#{filelist}#
diff --git a/htroot/Translator_p.java b/htroot/Translator_p.java
index e8d6998cd..31d97760f 100644
--- a/htroot/Translator_p.java
+++ b/htroot/Translator_p.java
@@ -41,10 +41,10 @@ public class Translator_p {
String langcfg = sb.getConfig("locale.language", "default");
prop.put("targetlang", langcfg);
if ("default".equals(langcfg) || "browser".equals(langcfg)) {
- prop.put("errmsg", "activate a different language");
+ prop.put("errmsg", 1); // msg: activate diff lng
return prop;
} else {
- prop.put("errmsg", "");
+ prop.put("errmsg", 0);
}
File lngfile = new File(sb.getAppPath("locale.source", "locales"), langcfg + ".lng");
diff --git a/locales/master.lng.xlf b/locales/master.lng.xlf
index 597df0df3..f64231d5b 100644
--- a/locales/master.lng.xlf
+++ b/locales/master.lng.xlf
@@ -8638,6 +8638,9 @@
<trans-unit id="7752d013" xml:space="preserve" approved="no" translate="yes">
<source>Target Language:</source>
</trans-unit>
+ <trans-unit id="67dd468b" xml:space="preserve" approved="no" translate="yes">
+ <source>activate a different language</source>
+ </trans-unit>
<trans-unit id="5ad17261" xml:space="preserve" approved="no" translate="yes">
<source>Source File</source>
</trans-unit>