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.urls import path
from . import views
urlpatterns = [
    path('', views.index, name='index'),]


mysite/urls.py

from django.contrib import adminfrom django.urls import include, path
urlpatterns = [
    path('polls/', include('polls.urls')),
    path('admin/', admin.site.urls),]

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at https://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/33f0ee3a-fcb7-4c4d-88cd-5d5a429be55e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to