Frameworks dont work as we want them too :P We have to understand how the defaults are implemented then make the changes as necessary ;-) If it can be customized, great! otherwise learn and use a different framework, LOLZ ;-)
Regards, Chetan Ganji +91-900-483-4183 ganji.che...@gmail.com http://ryucoder.in <https://www.avast.com/en-in/recommend?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=default3&tag=7ce9710f-d0c2-48a2-a0ba-76107578348e> I’m protected online with Avast Free Antivirus. Get it here — it’s free forever. <https://www.avast.com/en-in/recommend?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=default3&tag=7ce9710f-d0c2-48a2-a0ba-76107578348e> <#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2> On Fri, Mar 15, 2019 at 1:02 AM B <race...@gmail.com> wrote: > Thanks. I have things working fine under Ajax. This particular scenario is > an "odd one" since performing a GET on a delete view isn't common, but it > is implemented by Django. It is helpful for testing, but perhaps the right > approach is to "disable" get for the DeleteView and be done with it. My > main concern was for Django to behave "out of box" as intended without > overrides. > > On Thursday, March 14, 2019 at 3:24:46 PM UTC-4, Chetan Ganji wrote: >> >> https://www.django-rest-framework.org/topics/ajax-csrf-cors/ >> https://docs.djangoproject.com/en/2.1/ref/csrf/#ajax >> >> Regards, >> Chetan Ganji >> +91-900-483-4183 >> ganji....@gmail.com >> http://ryucoder.in >> >> >> >> <https://www.avast.com/en-in/recommend?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=default3&tag=7ce9710f-d0c2-48a2-a0ba-76107578348e> >> I’m >> protected online with Avast Free Antivirus. Get it here — it’s free >> forever. >> <https://www.avast.com/en-in/recommend?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=default3&tag=7ce9710f-d0c2-48a2-a0ba-76107578348e> >> <#m_8157490019364007879_CAMKMUjuRMSAqgVxdtNPHEt+RpSzM-VAx9rTgJf7CBqZ91UFtrg@mail.gmail.com_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2> >> >> On Fri, Mar 15, 2019 at 12:34 AM B <rac...@gmail.com> wrote: >> >>> I'm implementing a DeleteView, and for completion I would like to >>> provide the functionality indicated here: >>> >>> >>> https://docs.djangoproject.com/en/2.1/ref/class-based-views/generic-editing/#deleteview >>> >>> *If this view is fetched via GET, it will display a confirmation page >>> that should contain a form that POSTs to the same URL.* >>> >>> However, by default a GET will not include the required context to the >>> template for {% csrf_token %}. How do I include the appropriate context >>> information for a plain DeleteView CBV? >>> >>> -- >>> You received this message because you are subscribed to the Google >>> Groups "Django users" group. >>> To unsubscribe from this group and stop receiving emails from it, send >>> an email to django-users...@googlegroups.com. >>> To post to this group, send email to django...@googlegroups.com. >>> Visit this group at https://groups.google.com/group/django-users. >>> To view this discussion on the web visit >>> https://groups.google.com/d/msgid/django-users/213ca896-0973-4b64-9345-50de5cd9e5d7%40googlegroups.com >>> <https://groups.google.com/d/msgid/django-users/213ca896-0973-4b64-9345-50de5cd9e5d7%40googlegroups.com?utm_medium=email&utm_source=footer> >>> . >>> For more options, visit https://groups.google.com/d/optout. >>> >> -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to django-users+unsubscr...@googlegroups.com. > To post to this group, send email to django-users@googlegroups.com. > Visit this group at https://groups.google.com/group/django-users. > To view this discussion on the web visit > https://groups.google.com/d/msgid/django-users/98106b93-47ac-4cbb-8c89-d3291d52b2a5%40googlegroups.com > <https://groups.google.com/d/msgid/django-users/98106b93-47ac-4cbb-8c89-d3291d52b2a5%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this group, send email to django-users@googlegroups.com. Visit this group at https://groups.google.com/group/django-users. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAMKMUjvEymdFUtQ0qeaPHsie0PsjeuvwkdQC_kkHuHdoeMi8zw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.