1
0
mirror of https://github.com/django/django.git synced 2025-06-05 11:39:13 +00:00

Added a note about the AJAX CSRF example not working on jQuery 1.5

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16543 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Brian Rosner 2011-07-14 18:36:05 +00:00
parent 3b77458371
commit 99cd76e273

View File

@ -128,6 +128,11 @@ that allow headers to be set on every request. In jQuery, you can use the
} }
}); });
.. note::
Due to a bug introduced in jQuery 1.5, the example above will not work
correctly on that version. Make sure you are running at least jQuery 1.5.1.
Adding this to a javascript file that is included on your site will ensure that Adding this to a javascript file that is included on your site will ensure that
AJAX POST requests that are made via jQuery will not be caught by the CSRF AJAX POST requests that are made via jQuery will not be caught by the CSRF
protection. protection.