Confused about serving an image or mp3 from a deployment

Is this not possible? I have html in my repl which can include a png when I host the png elsewhere but I’d like to serve a png and an mp3 for display and download from my repl deployment because i am using golang code to generate them both.

The png shows as a broken image icon (unless I host it elsewhere) and the mp3 acts like it’s also a missing file. I tried full well formed url’s and relative url’s. Thanks.

Hmm, I looked at other people’s repl’s and they seem to be using the usual way, with relative paths. Is it a permissions thing? i can’t use with an image in my repl root or folders. thanks again folks.

I’m really scratching my headi on this one… this is what I get from my deployment:

only the first one is hosted on my personal server, the others are all pointing to the same pixel’y image in my Repl’s root and within a folder 1 level deep. Please help?

I figured it out… For others seeking the answer in the future :

It was a Golang issue. I was not serving any static content as I didn’t add a fileserver to my code, just http stuff. Here is the code I needed.


where ‘/stored’ is a folder containing my assets within root.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.