Extremely simple question that I can't get a simple answer for in Docs

2010-05-19 Thread pyfreak
Frustratingly enough, docs.djangoproject.com tells you how to print out the HMTL for a single field in your form, but it uses a shell to demonstrate it: f = ContactForm() >>> print f['subject'] >>> print f['message'] However, I need to know how to do this in a template I tried placing my f

Re: Extremely simple question that I can't get a simple answer for in Docs

2010-05-19 Thread pyfreak
e "django forms" in the search box at docs.djangoproject.com > > And in the first result you have a lot of examples on how to print > everything from a form in your > template:http://docs.djangoproject.com/en/dev/topics/forms/ > > > > > > On Wed, May 19

Having to rstrip the " [] " from the end of your Key when posted?

2010-05-28 Thread pyfreak
I'm having to, in Javascript, create a dictionary ( my_dict = {} ), then put in some Arrays. my_dict["stringkey"] = Array("hey","hey1") my_dict["stringkey1"] = Array("more","stuff") In the views function: for key in request.POST: prop_rec = request.POST.getlist(key) The Pyth

Re: Having to rstrip the " [] " from the end of your Key when posted?

2010-05-28 Thread pyfreak
ST["imthekeyval[]"] = ("someval", "anotherval", "imthekeyval") code: for key in request.POST.getlist(key): py_array = request.POST.getlist(key) ( py_array has all I need, no need to use the key which is sporting the mutant "[]"

Re: Having to rstrip the " [] " from the end of your Key when posted?

2010-05-29 Thread pyfreak
t; There's no "nice" way around it other than to recognise that any JS > arrays will have this suffix. > > Euan > > On 29 May, 05:33, pyfreak wrote: > > > > > I accept this as normal now. I think, what I'll need to do if I'm > > a

not understanding the OAuth2 docs

2010-05-31 Thread pyfreak
I plan on utilizing: http://github.com/simplegeo/python-oauth2 for my django-based Twitter app, however I'm wondering if anyone here who understands the django example, understands it better than I do. The first half of the page has an example for just plain Python, and there's a part there, whe