question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Improve language determination for AspNet MVC 5.x version

See original GitHub issue

Like we did for AspNet Core: https://github.com/aspnetboilerplate/aspnetboilerplate/issues/2103

Implemented Final Behaviour

  1. Use Abp.Localization.CultureName QueryString value if present.
  2. If user is known via IAbpSession and explicitly selected a language before (and saved to ISettingManager) then use user’s preferred language. If user is known but not selected any language and cookie/header (see below) has a value, set user’s setting with that information.
  3. Use Abp.Localization.CultureName header value if present.
  4. Use Abp.Localization.CultureName cookie value if present.
  5. If there is an default/application/tenant setting value for the language, then use the setting’s value.
  6. Use Accept-Language header value if present (automatically sent by browsers).

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
tom177ycommented, Jun 30, 2017

I m using AspNetZero Template v3.2 (MVC5+AJ1) and upgraded ABP from v1.5.0 to v2.1.3.
Am I right to say it still NOT possible for user’s with preferred language set, the system will automatically show his/her preferred language instead of system default language?

0reactions
Moustafa20commented, Aug 2, 2017

thank you

Read more comments on GitHub >

github_iconTop Results From Across the Web

C# language versioning - C# Guide
Learn about how the C# language version is determined based on your project and the reasons behind that choice. Learn how to override...
Read more >
MVC5 How to set language based on top level domain
The site content is localised using RESX files and users can switch language via a cookie for persistence and a HttpModule which sets...
Read more >
ASP.NET MVC 5 Internationalization
We will build an ASP.NET MVC 5 web application that contains the following features: It can display contents in different languages.
Read more >
Set C# Language Version for All the Projects in a Solution
In this article we will discuss how can we centrally manage the C# language version of multiple projects within a solution.
Read more >
Upgrade from MVC 4 to 5
This document describes the steps needed to upgrade an existing Optimizely Content Management System (CMS 8) solution from ASP.NET MVC 4 to MVC...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found