1. Create 'static' folder app/static/<appname>/<files>
2. update your urls.py in your project/urls as follows
from django.contrib import admin
from django.urls import path, include
from django.contrib.staticfiles.urls import staticfiles_urlpatterns
urlpatterns = [
path('', include('order.urls')),
path('admin/', admin.site.urls),
]
urlpatterns += staticfiles_urlpatterns()
3. add the following line at the starting of any HTML temple page (base.html)
{% load static %}
Comments
Post a Comment