internationalization

Greek and text-transform:uppercase

烂漫一生 提交于 2020-01-20 22:10:58
问题 I've written a web application that contains translations in several languages (one of them being Greek.) When displaying a certain translation on the title, the design rule was that the text is supposed to be uppercased, which in any other language in the world is fine, but when it comes to Greek, browsers don't know what to do with the accents (see this) so they display the wrong uppercased String. From that patch I've linked above, I've transformed it to Javascript, ran some use cases

Internationalization using resource bundle properties in JSP, non-Latin text becomes Mojibake

喜夏-厌秋 提交于 2020-01-20 04:12:26
问题 I have the following index.jsp: <%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> <%@ page contentType="text/html;charset=UTF-8" language="java" %> <fmt:setLocale value="ru_RU"/> <fmt:setBundle basename="messages"/> <html> <head> <title></title> </head> <body> <h1><fmt:message key="login"/></h1> </body> </html> And property file messages_ru_RU.properties: login = Логин The problem is that I get the junk unicode characters in the output: Ëîãèí Update Changed the .properies file

Best practice for localizing long text in Django?

Deadly 提交于 2020-01-17 05:38:24
问题 I just got done reading the Django docs on internationalization and something is bugging me. It seems like the default language strings are themselves used as the keys for retrieving translations. That's perfectly fine for short text, but for paragraphs, it seems like poor design. Now, whenever I change the English (default) text, my keys change and I need to manually update my .po file? It seems like using keys like "INTRO_TEXT" and retrieving the default language from it's own .po file is

asp net mvc url routing strategy and internationalization

跟風遠走 提交于 2020-01-17 04:43:06
问题 I have a website with urls like this : www.mysite.com/controller/action/id I need to create urls for others languages (english), so I have used ALEX ADAMYAN implementation of the MultiCultureMvcRouteHandler. So now I have urls like this : www.mysite.com/en/controller/action/id www.mysite.com/fr/controller/action/id but I need to keep my old urls has default one, ie to have : www.mysite.com/en/controller/action/id www.mysite.com/controller/action/id So I'm wondering how I can modify the routes

CakePHP translations in one or multiple po files and performance

穿精又带淫゛_ 提交于 2020-01-17 04:20:09
问题 Does making the i18n tool of CakePHP making its po file in single one file better than multiple files. Here I meant by performance. Personally, I prefer single one file I regarded it easier to translate the application, but I mean the performance of the application on the server. 回答1: I think that one file is better than multiple files, due to the performance used when opening and closing multi files is greater than opening one file regarding-less its size. 来源: https://stackoverflow.com

CakePHP translations in one or multiple po files and performance

不羁岁月 提交于 2020-01-17 04:20:06
问题 Does making the i18n tool of CakePHP making its po file in single one file better than multiple files. Here I meant by performance. Personally, I prefer single one file I regarded it easier to translate the application, but I mean the performance of the application on the server. 回答1: I think that one file is better than multiple files, due to the performance used when opening and closing multi files is greater than opening one file regarding-less its size. 来源: https://stackoverflow.com

Validating Locale-Specific “Customary” Date Formats

有些话、适合烂在心里 提交于 2020-01-17 03:59:18
问题 If I run this code... var cults = CultureInfo.GetCultures(CultureTypes.SpecificCultures); var exam = from c in cults from p in c.DateTimeFormat.GetAllDateTimePatterns('d') select new { Culture = c.DisplayName, Format = p }; ...I can see a dump of the various "short date" formats that Windows or .net thinks is customary or standard for different locales. But how would anyone independently confirm or verify these values? I recognize that Microsoft has invested possibly many 10's of thousands of

How do I encode Devanagari Back to English Encoding

一个人想着一个人 提交于 2020-01-17 02:51:16
问题 I am using 'Google Input Tools' for Devanagari Input in a Java application. Following is the scenario where I am typing Devanagari नमस्ते in one textField, I want to show it's English equivalent namaste in second textBox. How to do that? private void jTextField1KeyReleased(java.awt.event.KeyEvent evt) { // TODO add your handling code here: String input = jTextField1.getText(); jTextField2.setText(input); // I need code here to show input in English Encoding. System.out.println("Input "+input)

Advice on using FORMAT_MODULE_PATH

最后都变了- 提交于 2020-01-16 18:30:11
问题 From what I have read FORMAT_MODULE_PATH allows to use custom formats. How can I access the first value from DATETIME_INPUT_FORMATS in my application? The DATETIME_INPUT_FORMATS variable for german should be '%d.%m.%Y' , whereas for english should be '%Y-%m-%d' . I want to use the values from the formats.py files depending on the language. I followed the Django documentation for how to use the FORMAT_MODULE_PATH variable, but I don't get the expected results. settings.py: USE_L10N = True USE

Negative integer request parameters not recognized when language is Arabic, other languages like english, german, french & chinese work fine

安稳与你 提交于 2020-01-16 00:41:06
问题 I have a struts2 web-application. When I change the language to arabic, all query string urls, give un-certain results. I guess that's because ? is considered to be some variable name and then it's not mapped properly to the target action by Struts2. Although examples present on internet seems to work fine, so I guess this has something to do with my struts configuration. <constant name="struts.devMode" value="false" /> <constant name="struts.ognl.allowStaticMethodAccess" value="true"/>