Thank you for your response. It seems I needed:
from django.contrib.staticfiles.templatetags.staticfiles import static
and then from view.py, call static("image.png") and pass this to the context.
Not sure why exactly this works,
so if you care to elaborate, I'm all for learning. Thanks.
On
Hi friend,
Try to change {{STATIC_URL}} to
Thanks.
--
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+unsubscr...@googlegroups.com.
To post to
For whatever reason, after many hours of troubleshooting, I cannot seem to
insert a local static file into a template or raw html with "img src". An
image via a web url renders fine. Here are the relevant details:
Ownership of files is of the main user. Images are in the user's home
folder and
3 matches
Mail list logo