On Mon, 2009-08-03 at 11:29 -0700, mhulse wrote:
> Hello,
> 
> {{ form.start }}
> 
> For example, outputs this:
> 
> <input type="text" name="start_0" value="2009-08-10" id="id_start_0" /
> ><input type="text" name="start_1" value="12:00:00" id="id_start_1" />
> 
> I have tried:
> 
> {{ form.start_0 }} and {{ form.start_1 }}, but that outputs absolutely
> nothing. :)
> 
> Is it possible to split up the two fields so I can handle them
> individually?

Look at the SplitDateTimeWidget in django.forms.widgets.

> 
> Also, is it possible to control the XHTML output? I prefer use a DTD
> that does not allow an ending slash. :)

Django outputs XHTML. You don't get to control that. If you want
different output, you will need to write different widget classes and
customise each render() method on the widgets (all the output is done by
the widgets, so it's nicely encapsulated).

Search around before doing that, however. I have a vague feeling that
somebody might have started a project like this, but I haven't ever used
it.

Regards,
Malcolm


--~--~---------~--~----~------------~-------~--~----~
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