Hi guys I am getting this error every time i submit the form, when the
submit and the field is empty the error message appears, which
indicates that django does see the templates which I have set in the
settings.

Environment:


Request Method: GET
Request URL: http://127.0.0.1:8000/search/?q=Pro+.NET+Best+Practices

Django Version: 1.4 pre-alpha SVN-17229
Python Version: 2.7.2
Installed Applications:
('django.contrib.auth',
 'django.contrib.contenttypes',
 'django.contrib.sessions',
 'django.contrib.messages',
 'django.contrib.staticfiles',
 'django.contrib.admin',
 'django.contrib.admindocs',
 'projects.polls',
 'projects.books')
Installed Middleware:
('django.middleware.common.CommonMiddleware',
 'django.contrib.sessions.middleware.SessionMiddleware',
 'django.middleware.csrf.CsrfViewMiddleware',
 'django.contrib.auth.middleware.AuthenticationMiddleware',
 'django.contrib.messages.middleware.MessageMiddleware')

Template Loader Error:
Django tried loading these templates, in this order:
Using loader django.template.loaders.filesystem.Loader:
/Users/Tebogo/djcode/projects/projects/books/templates/
search_results.html (File does not exist)
Using loader django.template.loaders.app_directories.Loader:
/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-
packages/django/contrib/auth/templates/search_results.html (File does
not exist)
/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-
packages/django/contrib/admin/templates/search_results.html (File does
not exist)
/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-
packages/django/contrib/admindocs/templates/search_results.html (File
does not exist)
/Users/Tebogo/djcode/projects/projects/books/templates/
search_results.html (File does not exist)



Traceback:
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/
site-packages/django/core/handlers/base.py" in get_response
  111.                         response = callback(request,
*callback_args, **callback_kwargs)
File "/Users/Tebogo/djcode/projects/projects/books/views.py" in search
  18.                 {'books': books, 'query': q})
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/
site-packages/django/shortcuts/__init__.py" in render_to_response
  20.     return HttpResponse(loader.render_to_string(*args,
**kwargs), **httpresponse_kwargs)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/
site-packages/django/template/loader.py" in render_to_string
  169.         t = get_template(template_name)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/
site-packages/django/template/loader.py" in get_template
  145.     template, origin = find_template(template_name)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/
site-packages/django/template/loader.py" in find_template
  138.     raise TemplateDoesNotExist(name)

Exception Type: TemplateDoesNotExist at /search/
Exception Value: search_results.html

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to