Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5987445
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T22:48:57+00:00 2026-05-22T22:48:57+00:00

The server is hosting Asp.net mvc3 app and the Browser culture is set to

  • 0

The server is hosting Asp.net mvc3 app and the Browser culture is set to da (Danish)

GET request url: /get?d=1.1  (note that the decimal separator is .)
return: da;1,1   (note that the decimal separator is ,)

GET request url: /get?d=1,1  (the decimal separator is ,)
return: Exception Details: System.ArgumentException: The parameters dictionary contains a null entry for parameter 'd' of non-nullable type 'System.Decimal' for method 'System.Web.Mvc.ContentResult get(System.Decimal)' in 'Intranet.Controllers.OrderController'. An optional parameter must be a reference type, a nullable type, or be declared as an optional parameter. Parameter name: parameters

But given the same input to a post request, the results are exactly opposite.

POST request url: /get2    (form data d=1.1)
return: Exception ...

POST request url: /get2    (form data d=1,1)
return: da;1,1

I suppose the POST request is working as expected. But why does the GET request behave differently? How does the default model binder work in this case.

  • 1 1 Answer
  • 1 View
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T22:48:58+00:00Added an answer on May 22, 2026 at 10:48 pm

    When you send the data through a post, the locales take effect. When you send the data through a GET, it always uses the invariant locale.

    It seems this is done because you could copy and paste an URL, and send it to someone in another country. If the language of the browser was considered when a parameter is included in the URL (GET) the URL would break (it’s more obvious if you think about date formats than decimal separators).

    Among other places, it’s mentioned here by a member of the .Net team: http://forums.asp.net/t/1461209.aspx/1?Nullable+DateTime+Action+Parameters+Parsed+in+US+format+irrespective+of+locale+

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is it necessary that we need to install asp.net mvc on hosting server to
I have an ASP.NET app that exposes a Microsoft ReportViewer (actually an MVC3 app
I need to set up asp.net and SQL server database hosting with a 3rd
I am looking for a ASP.NET 4 and MS SQL Server 2008 hosting. I
Using asp.net mvc2 on vs2008 on local machine and hosting on a shared server
I have a asp.net web application that I was hosting somewhere. I backed up
What is the best to determine the Microsoft OS that is hosting your ASP.NET
So I have a shared hosting for ASP.NET MVC3 and I just created a
I'm currently using ASP.NET MVC3 and MongoDB for a web app. MongoDB uses UTC
I'm stumped. I've got an asp.net mvc app being hosted on a shared hosting

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.