Django

Code

Changeset 4612

Show
Ignore:
Timestamp:
02/26/07 11:43:41 (2 years ago)
Author:
jacob
Message:

Added a comment to the 404/500 views so that people with DEBUG=False and no 404/500 template will get a clue about which template to create.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/django/views/defaults.py

    r3193 r4612  
    7676            The path of the requested URL (e.g., '/app/pages/bad_page/') 
    7777    """ 
    78     t = loader.get_template(template_name) 
     78    t = loader.get_template(template_name) # You need to create a 404.html template. 
    7979    return http.HttpResponseNotFound(t.render(RequestContext(request, {'request_path': request.path}))) 
    8080 
     
    8686    Context: None 
    8787    """ 
    88     t = loader.get_template(template_name) 
     88    t = loader.get_template(template_name) # You need to create a 500.html template. 
    8989    return http.HttpResponseServerError(t.render(Context({})))