This was originally posted on blogger here.
Django Uni-Form is my answer to a problem with the Django forms API in that they do not play so well in the arena of the disability access. The default view uses tables which is not disabled friendly. Other views build forms as paragraphs or lists, neither which is optimal for attractive display of HTML forms.
I tried to make it as Django generic as I could, but as a Django newbie it is probably a bit rough around the edges. The code, if you examine it, is really clean. I like that about Django efforts - there is no boilerplate!
Anyway, after a bit of setup, you do an easy modification of the form templates that are presenting your Django forms. You should also style it a bit to match your preferences.
Some final notes and comparisons:
- Time to get a basic version running was about 45 minutes.
- Time to get the styling working was about 1 hour (mostly a stupid mistake on my part).
- I'm hoping the Pinax project will incorporate my efforts! ;)
- The Django docs were very clear on everything I needed to do. I did not have to leave https://docs.djangoproject.com to accomplish my chosen task. I cannot stress enough that this is something I really enjoy about Django.
- This was fun and easy.
Edit on 7/15/2010: Changed the link to django-uni-form on github.
1 comments captured from original post on Blogger
pydanny said on 2010-07-15
John, please use the github version, not the google code version!
Tags: django pinax legacy-blogger