We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 119874f commit 5d79c1fCopy full SHA for 5d79c1f
README.rst
@@ -27,6 +27,11 @@ If you have ideas for other panels please let us know.
27
28
* Note: The Debug Toolbar only works on Django 1.2 and newer.
29
30
+To disable the toolbar on a per request basis, add DISABLE to the query string::
31
+
32
+http://domain.com/path?DISABLE=disable
33
34
35
Installation
36
============
37
debug_toolbar/middleware.py
@@ -63,6 +63,9 @@ def _show_toolbar(self, request):
63
if getattr(settings, 'TEST', False):
64
return False
65
66
+ if request.REQUEST.get('DISABLE', False):
67
+ return False
68
69
x_forwarded_for = request.META.get('HTTP_X_FORWARDED_FOR', None)
70
if x_forwarded_for:
71
remote_addr = x_forwarded_for.split(',')[0].strip()
0 commit comments