Hallo, I don`t know what is wrong with my code, but I can not call a view in the urls.py of my site:
I have an application hspoints. In the folder is a views.py. In will post a view files: settings.py of my Site: (...) INSTALLED_APPS = ( 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.sites', 'django.contrib.messages', 'django.contrib.admin', 'hspoints' ) (...) view.py of my application hspoints: from django.http import HttpResponse def index(request): return HttpResponse("Hello, world. You're at the index.") urls.py of my Site: from django.conf.urls.defaults import * from django.contrib import admin admin.autodiscover() urlpatterns = patterns('', (r'^hspoints/$', include(hspoints.views.index)), (r'^admin/', include(admin.site.urls)), ) When i start the testserver with http://127.0.0.1:8000/hspoints/ I get: NameError at /hspoints/ name 'hspoints' is not defined When I add import hspoints to the urls.py of my site, what I did not have to do in the poll tutorial, I get: AttributeError at /hspoints/ 'module' object has no attribute 'views' What am I do wrong? I just don`t get what I forgot to do... Info: I`m working with PyDev in Eclipse. Thank you! -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@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.