Ajax post javascript date as UTC OR server Time Ajax post javascript date as UTC OR server Time json json

Ajax post javascript date as UTC OR server Time


There is toISOString() function which returns dates in standardized format and always does zero time zone.

Server accepts dates in local zone, so you need to do next date.ToUniversalTime().

So javascrript date.toISOString() equals to c# date.ToUniversalTime().