diff --git a/mysite/__pycache__/urls.cpython-310.pyc b/mysite/__pycache__/urls.cpython-310.pyc index 37e3400..11dad6e 100644 Binary files a/mysite/__pycache__/urls.cpython-310.pyc and b/mysite/__pycache__/urls.cpython-310.pyc differ diff --git a/mysite/__pycache__/wsgi.cpython-310.pyc b/mysite/__pycache__/wsgi.cpython-310.pyc new file mode 100644 index 0000000..29a571d Binary files /dev/null and b/mysite/__pycache__/wsgi.cpython-310.pyc differ diff --git a/mysite/urls.py b/mysite/urls.py index f46d600..b5450d1 100644 --- a/mysite/urls.py +++ b/mysite/urls.py @@ -14,8 +14,9 @@ Including another URLconf 2. Add a URL to urlpatterns: path('blog/', include('blog.urls')) """ from django.contrib import admin -from django.urls import path +from django.urls import path, include urlpatterns = [ - path('admin/', admin.site.urls), + path("polls/", include("polls.urls"), name="polls_index"), + path('admin/', admin.site.urls) ] diff --git a/polls/__pycache__/__init__.cpython-310.pyc b/polls/__pycache__/__init__.cpython-310.pyc new file mode 100644 index 0000000..9669271 Binary files /dev/null and b/polls/__pycache__/__init__.cpython-310.pyc differ diff --git a/polls/__pycache__/urls.cpython-310.pyc b/polls/__pycache__/urls.cpython-310.pyc new file mode 100644 index 0000000..35e5404 Binary files /dev/null and b/polls/__pycache__/urls.cpython-310.pyc differ diff --git a/polls/__pycache__/views.cpython-310.pyc b/polls/__pycache__/views.cpython-310.pyc new file mode 100644 index 0000000..ec96669 Binary files /dev/null and b/polls/__pycache__/views.cpython-310.pyc differ diff --git a/polls/urls.py b/polls/urls.py new file mode 100644 index 0000000..0399e3f --- /dev/null +++ b/polls/urls.py @@ -0,0 +1,7 @@ +from django.urls import path + +from . import views + +urlpatterns = [ + path("", views.index, name = "index") +] \ No newline at end of file diff --git a/polls/views.py b/polls/views.py index 91ea44a..06f3242 100644 --- a/polls/views.py +++ b/polls/views.py @@ -1,3 +1,4 @@ -from django.shortcuts import render +from django.http import HttpResponse -# Create your views here. +def index(request): + return HttpResponse("hello from within the poll index!") \ No newline at end of file