Hello,

I am serializing an QuerySet into json for being used by Javascript in the
browser. One of the fields which is serialized is a Django DateTime field.
When it is serialized, it gets represented as yyyy-mm-dd hh:mm:ss

However in the browser I would like to display the date as 'August 5, 2009
4:12'

One way to do this is to accept whatever String Django generates and then
parse it in Javascript to display what I want to display. Another way is to
get the desired format in the serialized JSON String.

Is it possible to control the serialization process to change some data as
it is being serialized, or alternately associate some format with the
QuerySet so that it returns the date in a certain format?

-- 
Thanks & Regards
Parag Shah

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to