Glogalizing jQuery Validation for Number and Date

The jQuery validation and the jQuery unobtrusive validation are frameworks for client validation. The default implementation uses the en-US culture, that is, number in the format of dot deparating the decimal places and date in the format MM/dd/yyyy. In this post we will customize that according with the culture chosen by the user.

Continuar lendo “Glogalizing jQuery Validation for Number and Date”

Anúncios
Glogalizing jQuery Validation for Number and Date

Globalizing DateTime and Decimal in ASP.NET MVC Using ModelBinder

If you already develop an ASP.NET MVC application in your computer that has some specific culture, pt-BR in my case, and after you publish to a server that has a different one, Azure using en-US in my case, you will have some unexpected results when typing date and decimal values. In this post I will show how to have sure that your application will work as expected in any server. We will accept values corresponding to the culture chosen by the user.

Continuar lendo “Globalizing DateTime and Decimal in ASP.NET MVC Using ModelBinder”

Globalizing DateTime and Decimal in ASP.NET MVC Using ModelBinder

Customizing ASP.NET MVC to Serialize Json DateTime in a More Natural Way

If you develop with ASP.NET MVC and use the JsonResult in response from an AJAX call, already had the problem that the DateTime is serilized in the format /Date(Ticks)/. this happens because the JsonResult uses JavaScriptSerializer to serialize the object.

Continuar lendo “Customizing ASP.NET MVC to Serialize Json DateTime in a More Natural Way”

Customizing ASP.NET MVC to Serialize Json DateTime in a More Natural Way