locale

Set my locale in iphone

Hi All, I am doing an application which user count down timer. The timer works fine with my simulator. but when i install it in to my device the timer is showing some time difference. Hope its the problem with locale. Can any one provide me some help to fix this problem.?? Please... Thanks in Advance, Shibin ...

Parsing a date with short month without dot

Hello, I have a String that represents a date in French locale : 09-oct-08 : I need to parse that String so I came up with this SimpleDateFormat : String format2 = "dd-MMM-yy"; But I have a problem with the month part, that seems to be expected with a ending dot : df2.format(new Date()); gives me : 28-oct.-09 What is no...

localhost is slow sometimes

Hi there I'm using firefox as my default browser for my basic webdev learning process and I wish to know why when I'm doing some file transfer as ftp or p2p, accessing localhost takes so much time, as I was accessing an http server from the other side of the world. Any idea? Do you know how top fix it? ps: I'm using WAMP on a Windows...

Choose specific localization on an iPhone app

How can I let the user choose a specific localization in my app? I have a book and I'd like the users to be able to read all the different translations of it. ...

SimpleDateFormat and locale based format string

Hi, I'm trying to format a date in Java in different ways based on the given locale. For instance I want English users to see "Nov 1, 2009" (formatted by "MMM d, yyyy") and Norwegian users to see "1. nov. 2009" ("d. MMM. yyyy"). The month part works OK if I add the locale to the SimpleDateFormat constructor, but what about the rest? I...

How do I know if my PostgreSQL server is using the "C" locale?

I'm trying to optimize my PostgreSQL 8.3 DB tables to the best of my ability, and I'm unsure if I need to use varchar_pattern_ops for certain columns where I'm performing a LIKE against the first N characters of a string. According to this documentation, the use of xxx_pattern_ops is only necessary "...when the server does not use the s...

Locale change in Windows Vista isn't being reflected in .NET application.

I have changed my locale to English/Great Britain (en-GB) as described here. When running my C# .NET application, I was expecting that Thread.CurrentThread.CurrentUICulture and Thread.CurrentThread.CurrentCulture would reflect this en-GB setting. However, I'm still getting en-US. Is there something that I'm missing? ...

Google suggest API does not work with Chinese locale

Hi, everyone! I have a problem with Google suggest API when using Chinese locale. I am picking Chinese hieroglyphs at random and use the REST API to retrieve suggestions. Unfortunately, Google always return an empty list of suggestions (I am completely sure, that I convert my request in utf-8, and it is working fine with other languages...

Auto-detecting language files based off browser and URL combos with PHP

I have a site with many people from around the world. The entire thing is UTF-8 so people are free to submit content and speak in any language they wish - from Greek to English. Now the only thing that the user can't control is the built in site language used for things like navigation and instructions for registering. These strings are...

PHP Accessing the user's country (locale)

Is there a superglobal reference to the user's country or is using the IP against a database of IP to Country lookups the best way to go? ...

Adobe AIR: detect en_GB locale

Is there a way to detect if the user is running the AIR application under en_GB locale on Windows? Capabilities.language returns only "en" and Capabilities.languages[0] returns "en_US" :( ...

Question regarding country

locale = "hy_AM_REVISED" Which country does this locale belong to? ...

Explain the Need for Mutexes in Locales, Please

Reading the question Why doesn’t C++ STL support atoi(const string& ) like functions?, I encountered a comment which warned that GCC (at least) has a bug that can slow down multi-threaded applications which use ostringstream frequently. This is apparently due to a mutex 'needed' by the C++ locale machinery. Given my recent interest in g...

How do I get the current time in a different TimeZone in Java?

OK - I feel pretty dumb asking such a basic question, but hey. I'm trying to get the current time in a different timezone in a Java webapp. I've tried the following obvious solution: in my servlet, Calendar localCalendar = Calendar.getInstance(myBean.getTimeZone()); then I pass the calendar object through to a JSP as a request attribu...

Help needed on font for localized string

Hi, My client has given me a custom TTF font only for English. So my intention is to load that TTF only for English and for other languages it should fallback to the available System font. I am doing the following steps: Registering fonts with my app. Copying into Resources folder and add to my project. Loading the font with name. N...

How to set my java programs locale to ccjk?

I'm reading an XML file inside a product to collects its inventory information i.e. various components it contains and when they are installed. I know from the product properties file that locale of the product is "ccjk". It stands for simplified Chinese for Japanese and Korean I guess. I want to set the locale of the shell before I run ...

python locale strange error. what's going on here exactly ?

Hello. So today I upgraded to bazaar 2.0.2, and I started receiving this message (I'm on snow leopard, btw): bzr: warning: unknown locale: UTF-8 Could not determine what text encoding to use. This error usually means your Python interpreter doesn't support the locale set by $LANG (en_US.UTF-8) Continuing with ascii encoding. ...

Writing binary files using C++: does the default locale matter?

I have code that manipulates binary files using fstream with the binary flag set and using the unformatted I/O functions read and write. This works correctly on all systems I've ever used (the bits in the file are exactly as expected), but those are basically all U.S. English. I have been wondering about the potential for these bytes to ...

java locale getDisplayLanguage is missing a few locales

Hi, I'm using locale.getDisplayLanguage(otherLocale) to get display several languages names in one locale. If i'm using the following: Locale loc = new Locale("he","IL"); Locale loc2 = new Locale("fr","FR"); System.out.println(loc2.getDisplayLanguage(loc)); It doesn't print the french language name in Hebrew. Other locales that doesnt...

[C++] Can software be developed in a different "human language" in C/C++ ?

Hi, I am developing a test software where the user can enter a string where I must validate it as C++ variable syntax. Then I started wondering if people can develop in japanese or other idioms. When I typed "is" on some IDE, it poped up a list with a "isascii" function. Then I wondered if I can use that function to check for the lett...