0

I have saved photos in a directory on my server. However, whenever i try to fetch them, it either says 404 not found (if fetched directly via URL in a browser), or it shows the picture icon on a card. I need it specifically to put the photos as background photos of card elements. How can i achieve this?

So far, i tried putting the directory name/file name in the URL column for a card (example: DIRECTORY/#PHOTO_NAME_COLUMN#), but it simply doesn't want to show them. I want to remake the Movies list app from the tutorial for my own purposes.

  • APEX doesn't have direct access to files in the operating system. You would need to store them as BLOB objects in a database table, or (usually preferred) serve them as static content from a front-end web server and not from within APEX itself. – pmdba Aug 01 '23 at 19:46
  • @pmdba yeah but not to even be able to access them through a link in the web browser? that's the odd thing... as a workaround i could just post the localhost absolute link as media URL, but i can't access them even that way... – Chadmerdinger Aug 01 '23 at 20:53
  • what kind of link? do you have a web server configured to make them available as static content? – pmdba Aug 01 '23 at 22:30
  • @pmdba i have a tomcat that only has apex on it and ords. everything else is default – Chadmerdinger Aug 01 '23 at 23:09
  • 1
    Typically static content is served by a separate http front-end web server that reverse proxies servlet requests to Tomcat. If you don't have that and if you haven't configured the ORDS servlet container to *see* your static files, Tomcat won't know where to find them. If you don't have a separate web server, perhaps this would help: https://stackoverflow.com/questions/22965738/how-to-serve-static-files-in-my-web-application-on-tomcat – pmdba Aug 02 '23 at 00:37

0 Answers0