Csrf verification is used for cross site request forgery protection. In
earlier versions of django csrf_token was needed to be imported in views.py
file. In latest releases, however, ( I am using django 1.10), no such thing
is required. All you need to do is include {% csrf_token %} in your
template inside form tag.
Hope this helps.On Apr 6, 2017 2:59 AM, <[email protected]> wrote: > when i try to upload profile pic after login through form..it shows csrf > verification failed.. > Any answers why this is happening ??? > > -- > 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 [email protected]. > To post to this group, send email to [email protected]. > 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/3d13a000-7936-416a-83d5-a03b1a50e3da%40googlegroups.com > <https://groups.google.com/d/msgid/django-users/3d13a000-7936-416a-83d5-a03b1a50e3da%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 [email protected]. To post to this group, send email to [email protected]. 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/CA%2BJxxxD3XcPADWxyc87COY1KUU7MSN4%2BqNfr9-ECTGs0SzQJ1w%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.

