Getting path/URL of uploaded files |
(06-26-2020, 06:34 PM)dariusbaker Wrote: Seems like you already know the answer but you cannot access assets in /app/writable/uploads using HTTP because that folder is outside the webroot. If you want to display the image using some HTML tag then you will have to move (or copy) the image into the webroot somewhere, i.e. /public/assets/images/20200626/somefile.jpg. The absolute path to the file would be PHP Code: $imagePath = WRITEPATH . 'uploads/' . $imageLocation; Assumes $imageLocation comes from the database and includes the date folder and the file's full name. |
Messages In This Thread |
Getting path/URL of uploaded files - by dariusbaker - 06-26-2020, 06:34 PM
RE: Getting path/URL of uploaded files - by lokeshk - 06-27-2020, 12:30 AM
RE: Getting path/URL of uploaded files - by dave friend - 06-27-2020, 06:29 AM
|