On Fri, Jan 5, 2018 at 1:50 PM, Karl Ritchie <karlritc...@gmail.com> wrote:
> Hi I'm very new to Django. I tried searching for this but the answers I > found aren't very clear. I'm wanting to create links to PDF documents. > I've created an app called writing with a static folder with PDF files. At > first I just put an html link in the template file but it when I ran it it > said it couldn't find the file. > I think I have to change the View.py and URL.py in Writing but what do I > change it to and what do I put in the template file for the link? > > Karl, "A static file is a static file", it doesn't matter if it is a jpg or a pdf. You should read https://docs.djangoproject.com/en/2.0/howto/static-files/ and think that instead of img tags for jpgs you will use a tags for pdfs HTH! > > -- > 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 this group, send email to django-users@googlegroups.com. > Visit this group at https://groups.google.com/group/django-users. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/django-users/dcd1a1fc-3aac-4562-a8c3-159b846a44c0%40googlegroups.com > <https://groups.google.com/d/msgid/django-users/dcd1a1fc-3aac-4562-a8c3-159b846a44c0%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- 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 this group, send email to django-users@googlegroups.com. Visit this group at https://groups.google.com/group/django-users. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CA%2BFDnh%2Bjz9SSTyivi3DmuY7ZDAbz8rSJbZS7sxocuao%2BZ6F0cQ%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.