Another quick reminder for my sloppy memory:
in case you want to use a custom date format and you need validation (of course, why wouldn’t you?), sometimes may happen that the format you’re using is not recognised during the client validation phase.

In one of my side projects for example I am using the standard jquery unobtrusive validation along with globalize.js. Obviously I have a specific bundle configured for this:

var scriptBundle = new ScriptBundle("~/bundles/validation").Include(


In case you have not noticed, I have imported the Italian globalization script. Again, in case you don’t know, in Italy the date format is usually “day/month/year”, or specifically dd/MM/yyyy .

In order to make client validation work, all you have to do is include somewhere in your project this script:

<script type="text/javascript">
$ = function (value, element) {
return this.optional(element) || Globalize.parseDate(value, "dd/MM/yyyy", "it-IT");

that’s it!

Next time: server-side pagination and AngularJs!