August 2024
Intermediate to advanced
256 pages
5h 34m
English
In your project’s urls.py file (in this case pyweb/urls.py) modify the urlpatterns list to include the URLs from the homepage app.

At the bottom of the file, you’ll see urlpatterns variable list.
from django.contrib import admin
from django.urls import include, path
urlpatterns = [
path(‘admin/’, admin.site.urls),
path(‘’, include(‘homepage.urls’)),
]
The line path(‘’, include(‘homepage.urls’)) associates the empty string URL pattern (‘’) with the URLs defined in the ‘homepage.urls’ module. It uses the include function to include the URL patterns defined in the ‘homepage.urls’ module, typically located in the ‘homepage’ ...
Read now
Unlock full access