On Sun, 2007-10-28 at 08:48 -0700, crybaby wrote:
> For example, you are at this url:
> www.site.com/post/id/1
> 
> and view1.py display the view1.html for the above url.
> 
> In the view1.html, I have a form and need to submit some value to
> another view2.py
> 
> and validate, then send it back to view1.py so view1.html is displayed
> at the url: www.site.com/post/id/1.
> 
> Is this possible or I have to submit the form to view1.py rather than
> view2.py?
> 
> If this is possible, how do I do it?

Your form will have it's "action" attribute pointing to a URL that is
handled by view2.py. Then, at the end of view2, you send back an
HttpResponseRedirect that redirects the client to load the URL for view1
in their browser.

This is a fairly normal form processing path. See, for example,
http://www.djangoproject.com/documentation/newforms/#simple-view-example

Regards,
Malcolm

-- 
Depression is merely anger without enthusiasm. 
http://www.pointy-stick.com/blog/


--~--~---------~--~----~------------~-------~--~----~
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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to