Skip to content

Instantly share code, notes, and snippets.

@jaychoo
Created October 11, 2011 13:34
Show Gist options
  • Save jaychoo/1278089 to your computer and use it in GitHub Desktop.
Save jaychoo/1278089 to your computer and use it in GitHub Desktop.
Django admin 404/500 html, user login to admin page
from django.utils.functional import curry
from django.views.defaults import server_error, page_not_found
handler500 = curry(server_error, template_name='admin/500.html')
handler404 = curry(page_not_found, template_name='admin/404.html')
url(r'^accounts/login/$', 'django.contrib.auth.views.login', {'template_name': 'admin/login.html'}),
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment