Datetime format not working with slashes Kendo UI -
my web application has support multiple datetime formats, namely yyyy-mm-dd, yyyy.mm.dd, dd/mm/yyyy , mm/dd/yyyy. 2 first ones work perfectly, however, when use other 2 formats, slashes replaced dashes in initial print, makes them fail validation. however, if choose date, comes out correct (chosen) format.
i using culture sv-se.
i suspect (with no experience of kendo ui, experience of other date/time apis) "/" being treated "the culture-specific date separator". if want "exactly forward slash, regardless of culture" may need escape it.
how escaping performed depend on library, you'd use quotes, e.g.
dd'/'mm'/'yyyy mm'/'dd'/'yyyy
Comments
Post a Comment