Hello,
http://www.djangoproject.com/documentation/tutorial04/
I am getting template errors:
is there a step missing?
Thanks
Frank
here is my code:
from django.conf.urls.defaults import *
from mysite.polls.models import Poll
info_dict = {
'queryset': Poll.objects.all(),
}
urlpatterns = patterns('',
(r'^$', 'django.views.generic.list_detail.object_list', info_dict),
(r'^(?P<object_id>\d+)/$',
'django.views.generic.list_detail.object_detail', info_dict),
(r'^(?P<object_id>\d+)/results/$',
'django.views.generic.list_detail.object_detail', dict(info_dict,
template_name='polls/results.html')),
(r'^(?P<poll_id>\d+)/vote/$', 'mysite.polls.views.vote'),
# Uncomment this for admin:
(r'^admin/', include('django.contrib.admin.urls')),
)
here is the error:
TemplateDoesNotExist at /polls/
polls/poll_list.html
Request Method: GET
Request URL: http://localhost:8000/polls/
Exception Type: TemplateDoesNotExist
Exception Value: polls/poll_list.html
Exception Location:
C:\Python24\lib\site-packages\django\template\loader.py in
find_template_source, line 72
Template-loader postmortem
Django tried loading these templates, in this order:
a.. Using loader django.template.loaders.filesystem.load_template_source:
a.. c:/mysite/templates\polls/poll_list.html (File does not exist)
b.. Using loader
django.template.loaders.app_directories.load_template_source:
a..
C:\Python24\lib\site-packages\django\contrib\admin\templates\polls/poll_list.html
(File does not exist)
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---