Questions tagged [locale]

1

votes
0

answer
28

Views

PHP - How to make app read beautified locale uri parameter?

So instead of www.example.com?locale=en, I want to have www.example.com/en/ (or any other country code like de, nl...), so that locale part of uri is available in PHP code, so I could use it to determine in what language content should be displayed. Any kind of help would be appreciated. :)
Zoka
1

votes
0

answer
605

Views

Perl failed locales. How do you set it?

I am getting the following whenever I try and run perl on Ubuntu 18.04: perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LANGUAGE = (unset), LC_ALL = (unset), LC_CTYPE = 'en_GB.UTF-8', LANG = 'en_US.UTF-8' are supported and installed on your system. perl:...
John Crawford
1

votes
0

answer
40

Views

Changing the language of menu items

I'm trying to add a new locale and the language change option to a menu I created. Below you can see the code that I have my progress so far Essentially, I'd like the menu items for 'sports' and 'districts' to change to Chinese after the radio button for '中文“ is clicked. My JavaScript skill...
Brian Hebert
1

votes
0

answer
43

Views

Can std::wofstream << WCHAR and << CHAR at the same time?

How can we write WCHAR and CHAR to a wofstream at the same time?like this: wofstream
Li Da
1

votes
1

answer
32

Views

language specific chars base letter and sorting

I'm trying to print out a sorted list of items and print the first letter as a 'group' headline for each item. The code is used on the client side. . The sorting works just fine, the problem is when language specific chars is sorted in another locale. For example is å treated as ain en-GB and ñ as...
anderssonola
1

votes
0

answer
66

Views

Incomplete UTF8 char for UTF8 imbued std stream

I recently got a weird bugreport. The problem is that the following produces an incomplete UTF8 char on some machines: #include #include int main() { std::cout.imbue(std::locale('fr_FR.UTF-8')); std::cout
Flamefire
1

votes
0

answer
70

Views

Resolving lint's deprecated warnings without using @SuppressWarnings

I have a feeling I can deal with the above warning without forcibly suppressing it. However, this doesn't seems to work: static Context updateResources(Context context) { Resources resources = context.getResources(); Configuration config = new Configuration(resources.getConfiguration()); SharedPrefe...
PIXP
1

votes
0

answer
105

Views

Apache POI: German cell format in concatenated string cell

I've got an Excel-(xlsx-)file with two cells: A1 is numeric with value '5.3' B1 is formula ='Number: '&A1 When I open this Excel-file in German LibreOffice or Excel then both show me cell content with comma-separator: A1: 5,3 B1: Number: 5,3 When I read the contents with Apache POI (version 3.17; ne...
S. Doe
1

votes
1

answer
77

Views

How to correctly localize Android resources to support multiple languages?

I've been working on an Android application that is going to be used throughout different countries. Because of this I have followed the Android Developer Guide to support different languages for an application and used the Translation Editor in Android Studio to specify the resources I want transla...
MasterQueue
1

votes
0

answer
21

Views

Excel 2010 - Open file with different locale

I work in a closed Windows environment and I am not able to change the Windows Locale. I am going to receive on a regular basis excel files written in the French Locale and when I open them in my English Locale settings at work, the dates are changed. (from yyyy/mm/dd to dd/mm/yyyy). This is done a...
LAmaral
1

votes
0

answer
30

Views

Can we check if the locale output from boost::locale::generator::generate is invalid?

This is a 2-part question that began with me wondering: what happens if the ID input to boost::locale::generator::generate() was some invalid value? I checked the documentation and I couldn't find anything on what happens if we passed in something like test instead of en_CA.UTF-8. I know that no exc...
cechow
1

votes
1

answer
137

Views

Angular matDatepicker locale fail typing in input box

If I use a datepicker as in and set a locale as in providers: [ { provide: LOCALE_ID, useValue: 'it-IT' }, { provide: MAT_DATE_LOCALE, useValue: 'it-IT' }] it works if the user select date from picker, but if he types inside the input box the date is not parsed in the right way. Eg: the Italia...
user2959635
1

votes
0

answer
33

Views

Symfony user sticky locale

In the past two days I've been trying to make my custom LocaleSubscriber, a subscriber which is supposed to set user's locale to user's preference or to default.
GasKa
1

votes
3

answer
344

Views

How to change Locale? Not working on some Devices

I'm writing app that support two language and I'm changing language with Change app Locale here my code : Locale locale = new Locale('fa'); Locale.setDefault(locale); Configuration configs = new Configuration(); configs.locale = locale; getBaseContext().getResources().updateConfiguration(configs,...
The Jake
1

votes
0

answer
26

Views

Changing locale inside package function

I have a function which resides inside a package, assume the function is called foo(). I want it to read an Excel file with Greek letters, so I change the locale to Greek. After reading in the datafile I do something with this data and the Greek characters and after that I want the locale changed ba...
Veerle
1

votes
1

answer
83

Views

Changing input method on the fly

I have a simple form on laravel which will take name and email only and submit it to database. Name will be in Japanese. I can validate it in controller. However, when I am using chrome; after inserting the name in Japanese; I press TAB key and input method automatically changes when cursor is on th...
Nabil Farhan
1

votes
1

answer
131

Views

Display ISO 8601 date string as local date and time based on navigator.language

I've been trying to display the local date and time after parsing ISO string to local timestamp based on navigator.language. let sampleDate = new Date('2018-11-29T09:54:46.863207Z').toLocaleString(navigator.language); So when I change the browser language preferences it reflects the date format in p...
kal93
1

votes
2

answer
62

Views

Locale not available in PostgreSQL 9.6 on Jelastic 5.4

I have an automated deployment procedure, based on bash scripts, that creates a database on a PostgreSQL node on a Jelastic environment. My provider is using version 5.4 of the Jelastic platform. The automated procedure has been used dozens of times successfully, but it refuses to run today. My olde...
Esteban
1

votes
1

answer
80

Views

Invalid unicode character causing MySQL string error

I need to add a record to our MySQL database (via Omeka) that includes an invalid unicode character (this one) The error message I get via Omeka is: Mysqli statement execute error : Incorrect string value: '\xF0\xAA\xA8\xA7\xE7\x94...' for column 'text' at row 1 The database field is longtext with...
Another_Omeka_User
1

votes
1

answer
68

Views

C# DateTime toString behaves differently on windows server 2012 and 2016

I have the same instance of an application on a windows server 2012 and another on a windows server 2016, But in 2012 version, C# toString('yyMMddHHmmss') on DateTime object behave differently than 2016 version ! Here is the log of toString I get in 2012 server: Info Culture is: fa-IR Info UiCultur...
Rathma
1

votes
1

answer
76

Views

Flutter:Equivalent to NSLocale (iOS) & Locale (Android)

I am trying to get ISOCountryCodes(list) from the phone system. I use NSLocale.isoCountryCodes in iOS native and Locale.getISOCountries() in the case of Android native. I am trying to do a new app in Flutter , was looking for the API for ISOCountries, couldnt find any in documentation. Does Flutter...
anoop4real
1

votes
1

answer
315

Views

Angular Material DatePicker's input shifts month and day after typing

I'm developing a app using Ionic 4/Angular 7 and Angular Material 7.2.1. The app uses brazilian date format DD/MM/YYYY. When I select the date with the datepicker itself the text in the input is fine. But, after type the date in the datepicker's (on blur) input, the month and day are switched. For e...
Natanael
1

votes
1

answer
41

Views

Win32 raw input blocks input locale switching when RIDEV_NOLEGACY is specified

I'm writing a keyboard input system for Windows based on Raw Input. It is implemented with RIDEV_NOLEGACY flag set, and legacy keyboard messages are generated manually, only when input was not processed by clients. I've managed to get it working but language switching hotkey (Alt+Shift in my case) i...
Niello
1

votes
0

answer
43

Views

How can I determine std::isgraph in any language for a UTF-8 string?

I'm researching string encodings and locales. Oh joy! Essentially I want to check that every character in a UTF-8 string is graphical, like isgraph but for all Unicode characters. Here's what I've established so far, but I don't know how to put it together. I can extract the characters from a UTF-8...
spraff
1

votes
1

answer
43

Views

Maven and Java locales in MacOS

I need to build a Maven project on a macOS 10.14 machine with Java 8. For various reasons, I would prefer to keep my system using my 'real' locale (that is, my system settings panel should list 'German' as the locale, time, currency and number formats), but I need my code to be compiled using the '...
jstarek
1

votes
1

answer
40

Views

Under what conditions does VoiceOver automatically switch language in an iOS app

My phone is set to en_us as system language, and I have added Swedish and French to the VoiceOver rotor languages. After adding the languages I find that the VoiceOver/Safari combo automatically starts in the appropriate language when browsing web pages where the document contains a language settin...
Pacificana
1

votes
1

answer
63

Views

NumberFormat.getCurrencyInstance() not returning currency symbol for Locales CHINA and FRANCE (jdk-1.8)

I have written a program to return double values with the currency symbols of some countries. For this I am using getCurrencyInstance() method to get symbol of particular country. The problem is specific to my laptop's JDK-1.8 and works fine on online compiler. The problem, I am facing is that the c...
Rainbow Coder
1

votes
1

answer
45

Views

Keyboard - detect all languages, change language, install language

I'm looking for a solution to these problems: 1) How to change Android Keyboard language? 2) How to detect all installed keyboard languages? 3) How to install some keyboard language? Are these problems possible to do? I found some info: Ad 1) I think this is not possible right (without permission an...
Pepa Zapletal
1

votes
1

answer
39

Views

Handling chinese characters in SQL Server 2016

Our ETL team is sending us some data with chinese description. When we are loading that data in our SQL Server database, those descriptions are coming up as blank. We tried changing the column format to nvarchar, but that doesnt help. Can you please help. Thanks
Newbie
1

votes
1

answer
56

Views

toLowerCase(). need help understanding this in a more real world way

console.log('ALPHABET'.toLocaleLowerCase()); console.log('\u0130'.toLocaleLowerCase('tr') === 'i'); console.log('\u0130'.toLocaleLowerCase('en-US') === 'i'); let locales = ['tr', 'TR', 'tr-TR', 'tr-u-co-search', 'tr-x-turkish']; console.log('\u0130'.toLocaleLowerCase(locales) === 'i');
David Arriaga
1

votes
0

answer
35

Views

How to prevent application's locale changing when user changes Windows date/time format (C++, Windows native app)

Our application is a Windows native 64 bit application developed in C++ (Visual Studio) with RogueWave's Stingray library, itself using MFC for the UI. In the application, dates are shown in various places (grids, dialog box controls etc.). As it is a complex business application, we handle the date...
Scrontch
1

votes
0

answer
34

Views

Magento 2 is sending Emails in english if sent programmatically

I'm looking for hours now and I found some topics that are similar but none of them solved my issue. I'm writing a Magento 2.3 Extension to import customers from a different Database. Everything works fine except for the email language. I would expect Magento to use automatically the correct languag...
Gordon Freeman
1

votes
1

answer
16

Views

Rendering view after changing Locale by Ajax in Symfony 4

I am trying to change page language by a dropdown. Dropdown is generated by this code {{ form_widget(registrationForm.locale, { 'attr': {'onChange': 'languageChange()'} }) }} in the twig. Ajax function function languageChange() { let selectedLanguage = $('#email_form_locale').val(); $.ajax({ url:...
saku
1

votes
0

answer
27

Views

How to get the CURRENT device language in android?

This question hes already been asked by different users, e.g. here. But nevertheless, I need to repeat it as the provided answers do not help to get the CURRENT device language. My test device is in German language and the app in English. I try to get the current device language as follows: Log.i('L...
Mark Delphi
1

votes
0

answer
45

Views

After updating AppCompat library to appcompat:1.1.0-alpha03 Locale configuration is not working anymore

After updating implementation 'androidx.appcompat:appcompat:1.1.0-alpha02' to implementation 'androidx.appcompat:appcompat:1.1.0-alpha03' locale settings was not working anymore, spent half day to figure out that library was the actual problem. Is there another NEW way for locale setting or workar...
Antonis Radz
1

votes
0

answer
34

Views

Android, Changing app language not working properly on oneplus and huawei

I am changing the app loacale like this, Language language = getPreferenceAppLanguage(); if (language == null) { return; } Locale locale = createLocale(language); Locale.setDefault(locale); Resources res = mContext.getResources(); Configuration config = new Configuration(res.getConfiguration()); if...
jaydeep_gedia
1

votes
2

answer
866

Views

How can I remotely (via web services) determine date format of SharePoint 2003 site, for use in Versions.asmx returned XML?

The GetVersions() call to the Versions.asmx web service in SharePoint 2003 returns a localised date format, with no way of determining what the format is. It's the site regional setting of date format, but I can't find a way to get even that out of SharePoint 2003. Locally, it looks like SPRegionalS...
Michael Baltaks
1

votes
1

answer
1.1k

Views

jQuery tablesorter month name locale

Using the jQuery tablesorter plugin . I wonder how could I make it work with dates in the full format: 'Jan 21, 2009 16:00' Problem is that when that date (a string) has been localized with user current locale 'gen 21, 2009 16:00' Do I have to write a custom sorter for each locale? Thanks. Da Al C...
1

votes
1

answer
521

Views

Java Locale issue in vendor Applet

I have a vendor Applet that is trying to use no longer supported locale settings. De compiled Code is as follows String s1 = System.getProperty('java.version'); String s2 = System.getProperty('user.language'); String s; if(s1.regionMatches(true, 0, '1.4', 0, 3)) s = System.getProperty('user.country...
Keibosh
1

votes
2

answer
1.3k

Views

PHP: Gettext problems

I can't seem to get gettext working, here. I'm using MAMP Pro and phpinfo(); says that gettext is enabled. I followed this tutorial: http://zez.org/article/articleview/42/1/ I have my strings declared in my code like this: _('test string'); Then I ran xgettest -L PHP test.php, which generated my mes...
neezer

View additional questions