Forums

Link to pdf on personal website

I would like to link to a pdf (say my_document.pdf) that is in /static/files, by providing someone the following link:

https://myname.pythonanywhere.com/static/files/my_document.pdf

This works just fine with an image (e.g., https://myname.pythonanywhere.com/static/files/my_image.png) will load the image and allow me to save it, but https://myname.pythonanywhere.com/static/files/my_document.pdf will lead to a 404 Page not Found error.

Is it not possible to do what I am trying to do? The website I have is a small Flask website if that matters.

Solved this - I had my_document.pdf in the wrong folder (I had two versions of my website and placed the pdf in the static folder of the old version).

Glad to heat that you solved it!