I’m able to upload files onto my webserver filesystem but I had a
regarding how I’d go about accessing them using the
If my files, i.e pictures, are being uploaded to
public/images//filename.jpg, then should I store the entire path,
just the picture name in my database table? I would imagine storing
the filename is better so that it’d be easy to move the file location
later. Also, if I’m using <img src= <%= @path %>>, then what should the
path be? What is the root directory from where it starts to try to find
file? Is it the view directory under app, OR, does it start from the
directory that holds the public and app directories? Should the path be
something like - ? I tried
but it couldn’t find the file?
Thanks in advance.