Sunday, April 22, 2018

Re: I know this question has been asked before, but I haven't found an answer that solves my situation. I'm looking at the Django tutorial, and I've set up the first URLs exactly as the tutorial has it, word for word, but when I go to

 I have made few changes take a look at it and try this one. I hope this will work.

On Sunday, April 22, 2018 at 10:53:58 PM UTC+5:30, Avitab Ayan Sarmah wrote:
polls/views.py
from django.http import HttpResponse      def index(request):      return HttpResponse("Hello, world. You're at the polls index.")

polls/urls.py
from django.conf.urls import url    from . import views    urlpatterns = [      url(r'^$', views.index, name='index'),  ]

mysite/urls.py
from django.contrib import admin  from django.conf.urls import include, url    urlpatterns = [      url(r'', include('polls.urls')),      url(r'^admin/', admin.site.urls),  ]

--
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 django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/fcc6b586-8ab1-4886-9e59-ba4a3d75c3aa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment