limas a écrit : <ot> Limas, please answer on the group, not privately </ot>
>> This is totally unrelated to Django and ModelForms. javascript runs on >> the browser, *after* the whole page containing the form has been sent >> by the server. IOW, at this stage, all you have is a plain old HTML >> form. > > Bruno, > First of all thank you for your comment. > But i have some doubts. You should not !-) > 1) The browser is receiving the form as a single bulk with fieldname > and control, i think it is as an array. What the browser receive is an HTTP response. IOW : text. You'll find a very exhaustive description of what's an HTTP response in the HTTP rfc: http://www.w3.org/Protocols/rfc2616/rfc2616.html > Then how can i set the value of a single textbox placed in between a > big form? for which definition of "setting the value" ? If what you mean is : "how do I change the "value" attribute of an HTML form on the browser using Javascript", then you're definitively on the wrong newsgroup. > If i use a loop like below > {% for field in form %} > {{ field.name }} {{ field }}<br> > {% endfor %} You'd getter better results using form.as_p IMHO. > The row field name is displaying rather than the verbose name. Of course, that's what you asked for. > 2) Handling form with javascript is through there name attribute of > each controlls. Not necessarily, but that's indeed the most common case. > When we using ModelForm, how can we get the "name" value for each > controll? How would this information help you setting the value using javascript ? > Hop you understand what i meant. > Sorry for my poor English... Well, hope you'll pardon me, but I don't know for sure if you are confused wrt/ how HTTP work or if it's just a language problem. If you really feel your English is too limited to clearly explain your problem, you should perhaps find someone around you that may help you rewriting your question. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---

