Basically, I am trying to add commentForm which is a modelForm to a blogview which is a detailsview. I am trying to build a blog with comment. Anyone could give some pointers on how to accomplish it? Any other alternative? Thanks.

asked 13 Sep '13, 16:30

John's gravatar image

John
111
accept rate: 0%


i will recommend not to use 2 class based views for one purpose i mean use detailview to show something and createview to create object so on instead use classic function based approach

if you still want to delve in then you can check form mixins

http://ccbv.co.uk/projects/Django/1.5/django.views.generic.edit/ModelFormMixin/

and you can read this

https://docs.djangoproject.com/en/dev/topics/class-based-views/mixins/

link

answered 14 Sep '13, 03:47

DjangoForum's gravatar image

DjangoForum ♦♦
636
accept rate: 8%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "Title")
  • image?![alt text](/path/img.jpg "Title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×12
×12
×1
×1

Asked: 13 Sep '13, 16:30

Seen: 3,644 times

Last updated: 14 Sep '13, 03:47

powered by OSQA