On Tue, Oct 21, 2014 at 4:19 PM, Sabine Maennel
<[email protected]> wrote:
> I really do not understand what is happening. I have a 404.html along with a
> 500.html in my template directory. They are both simple and look like this:
>
> 404.html:
>
> <h1>Server Error 404!</h1>
> <h3>Das netTeachers-Team ist informiert und kümmert sich darum.
> Wir hoffen auf Ihr Verständnis.</h3>
>
> 500.html:
>
> <h1>Server Error 500!</h1>
> <h3>Das netTeachers-Team ist informiert und kümmert sich darum.
> Wir hoffen auf Ihr Verständnis.</h3>
>
> When I put in a non existent url on runserver and DEBUG=False, I get this
> error in my log: [21/Oct/2014 16:08:56] "GET /x HTTP/1.1" 500 131
>
> It seems like he does not find my 404.html Template but why???
>
> My settings.py looks like this in the part of template directories:
>
> import os
> BASE_DIR = os.path.dirname(os.path.dirname(__file__))
>
> ROOT_URLCONF = 'netteachers.urls'
>
> TEMPLATE_DIRS = (
>     os.path.join(BASE_DIR, 'templates'),
> )
>
> CRISPY_TEMPLATE_PACK = 'bootstrap3'
>
> TEMPLATE_CONTEXT_PROCESSORS = (
>     "django.contrib.auth.context_processors.auth",
>     "django.core.context_processors.debug",
>     "django.core.context_processors.i18n",
>     "django.core.context_processors.media",
>     'django.core.context_processors.request',
>     "django.contrib.messages.context_processors.messages",
>     "core.context_processors.resolvermatch",
> )
>
> Please can anybody tell me what I am doing wrong! Thanks in advance!
>

You have DEBUG=True on, so you will never see your custom 404 page:

https://docs.djangoproject.com/en/1.7/ref/views/#http-not-found-view

Cheers

Tom

-- 
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 http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAFHbX1L%3D%2BkafgUq7YaZBNvAEdPwhT%2BEwFSh%3DHk5TAZ-7o%3DWVSQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to