Format Date Time
If you pass the datetime in json format ( and apply to the view with Knockout) then you will need some formatting – because the standard format is not good .
So I have used http://blog.stevenlevithan.com/archives/date-time-format – easy to understand and with examples.
Reccomended!
Intrebarea e – care e formatul in care ar trebui serializat un DateTime in format JSON? Cum nu prea exista un standard in sensul asta, fiecare alege ce vrea, din pacate..
JavascriptSerializer
JavaScriptSerialzer din .NET utilizeaza acel format ciudat pentru Date in JSON introdus de Microsoft..
La http://weblogs.asp.net/bleroy/archive/2008/01/18/dates-and-json.aspx explica de ce l-au ales, dar tot acolo spune Le Roy intr-un comment: “In any case, everybody’s moving away from this and using ISO strings despite their disadvantages. Nothing left to see here. Move along”