diff --git a/django/views/debug.py b/django/views/debug.py index 2e04905f61..87f71d1eb0 100644 --- a/django/views/debug.py +++ b/django/views/debug.py @@ -16,6 +16,7 @@ from django.utils.html import escape from django.utils.encoding import force_bytes, smart_text from django.utils.module_loading import import_string from django.utils import six +from django.utils.translation import ugettext as _ HIDDEN_SETTINGS = re.compile('API|TOKEN|KEY|SECRET|PASS|SIGNATURE') @@ -511,7 +512,17 @@ def technical_404_response(request, exception): def default_urlconf(request): "Create an empty URLconf 404 error response." t = Template(DEFAULT_URLCONF_TEMPLATE, name='Default URLconf template') - c = Context({}) + + c = Context({ + "title": _("Welcome to Django"), + "heading": _("It worked!"), + "subheading": _("Congratulations on your first Django-powered page."), + "instructions": _("Of course, you haven't actually done any work yet. " + "Next, start your first app by running python manage.py startapp [app_label]."), + "explanation": _("You're seeing this message because you have DEBUG = True in your " + "Django settings file and you haven't configured any URLs. Get to work!"), + }) + return HttpResponse(t.render(c), content_type='text/html') # @@ -1121,7 +1132,7 @@ DEFAULT_URLCONF_TEMPLATE = """ - Welcome to Django + {{ title }}