change this
url(r'^polls/', include('polls.urls')'),
for this
url(r'^', include('polls.urls')'),
On Fri, Jan 10, 2014 at 2:40 AM, AJ NOURI <[email protected]> wrote:
> I have Python 2.7.3
>
> I am new in django and I am following the tutorial 3 at :
> https://docs.djangoproject.com/en/1.6/intro/tutorial03/
>
> I followed exactly the steps described:
>
> Here is a copy/paste from files in the project:
>
> *cat polls/views.py*
>
> from django.http import HttpResponse
>
> def index(request):
> return HttpResponse("Hello, world. You're at the poll index.")
>
> from /mysite: *cat urls.py*
>
> from django.conf.urls import patterns, include, url
>
> from django.contrib import admin
> admin.autodiscover()
>
> urlpatterns = patterns('',
> url(r'^polls/', include('polls.urls')'),
> url(r'^admin/', include(admin.site.urls)'),
> )
>
> *cat polls/urls.py*
>
> from django.conf.urls import patterns, url
>
> from polls import views
>
> urlpatterns = patterns('',
> url(r'^$', views.index, name='index')
> )
>
> The page debug shows the following error:
> [image: enter image description here]
>
>
> It looks like, *it doesn't recognize the "polls" pattern in
> /mysite/urls.py.*
>
> Am I missing something?
>
> --
> 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/31d65899-e64f-4f5d-aac7-ea0dd67108f9%40googlegroups.com
> .
> For more options, visit https://groups.google.com/groups/opt_out.
>
--
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/CAM-7rO0eBdmMn9T2MTpG3uCfy2HThGKAY35bNZVO%2BLY1ZOhP1g%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.