--- django/utils/dateformat.py.ori	2008-05-19 09:46:47.000000000 +0200
+++ django/utils/dateformat.py	2008-07-01 14:35:45.000000000 +0200
@@ -18,7 +18,7 @@
 from calendar import isleap, monthrange
 import re, time
 
-re_formatchars = re.compile(r'(?<!\\)([aAbBdDfFgGhHiIjlLmMnNOPrsStTUwWyYzZ])')
+re_formatchars = re.compile(r'(?<!\\)([aAbBcdDfFgGhHiIjlLmMnNOPrsStTUuwWyYzZ])')
 re_escaped = re.compile(r'\\(.)')
 
 class Formatter(object):
@@ -103,6 +103,11 @@
         "Seconds; i.e. '00' to '59'"
         return u'%02d' % self.data.second
 
+    def u(self):
+        "Microseconds"
+        return self.data.microsecond
+
+
 class DateFormat(TimeFormat):
     year_days = [None, 0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334]
 
@@ -117,6 +122,13 @@
         "Month, textual, 3 letters, lowercase; e.g. 'jan'"
         return MONTHS_3[self.data.month]
 
+    def c(self):
+        """
+        ISO 8601 Format
+        Example : '2008-01-02 10:30:00.000123'
+        """
+        return self.data.isoformat(' ')
+
     def d(self):
         "Day of the month, 2 digits with leading zeros; i.e. '01' to '31'"
         return u'%02d' % self.data.day
--- docs/templates.txt.ori	2008-07-01 14:33:40.000000000 +0200
+++ docs/templates.txt	2008-07-01 14:33:44.000000000 +0200
@@ -916,6 +916,7 @@
     A                 ``'AM'`` or ``'PM'``.                     ``'AM'``
     b                 Month, textual, 3 letters, lowercase.     ``'jan'``
     B                 Not implemented.
+    c		      ISO 8601 Format				``2008-01-02 10:30:00.000123``
     d                 Day of the month, 2 digits with           ``'01'`` to ``'31'``
                       leading zeros.
     D                 Day of the week, textual, 3 letters.      ``'Fri'``
@@ -952,6 +953,7 @@
                       month, 2 characters.
     t                 Number of days in the given month.        ``28`` to ``31``
     T                 Time zone of this machine.                ``'EST'``, ``'MDT'``
+    u		      Microseconds				``0`` to ``999999``
     U                 Not implemented.
     w                 Day of the week, digits without           ``'0'`` (Sunday) to ``'6'`` (Saturday)
                       leading zeros.
--- tests/regressiontests/dateformat/tests.py.ori	2008-05-19 11:29:37.000000000 +0200
+++ tests/regressiontests/dateformat/tests.py	2008-05-19 11:49:31.000000000 +0200
@@ -5,6 +5,8 @@
 u'p.m.'
 >>> format(my_birthday, 'A')
 u'PM'
+>>> format(timestamp, 'c')
+u'2008-05-19 11:45:23.123456'
 >>> format(my_birthday, 'd')
 u'08'
 >>> format(my_birthday, 'j')
@@ -39,6 +41,8 @@
 True
 >>> no_tz or format(my_birthday, 'U') == '300531600'
 True
+>>> format(timestamp, 'u')
+u'123456'
 >>> format(my_birthday, 'w')
 u'0'
 >>> format(my_birthday, 'W')
@@ -88,3 +92,4 @@
 summertime = datetime.datetime(2005, 10, 30, 1, 00)
 wintertime = datetime.datetime(2005, 10, 30, 4, 00)
 the_future = datetime.datetime(2100, 10, 25, 0, 00)
+timestamp = datetime.datetime(2008, 5, 19, 11, 45, 23, 123456)


