I have my apache root as /var/www/html and have a sub-folder there as /var/www/html/Fontan.
The other files are located as /mnt/draid/Pictures/
In /var/www/html/Fontan I have a PHP script using opendir() to try to access the files to output a simple <img> tag for each. But it won't work.
If I go for other files with opendir('../otherfolder/Pictures/') it works fine, but not when I try opendir('/mnt/draid/Pictures/'). I have also tried to create a softlink as /var/www/html/Pictures pointing to /mnt/draid/Pictures and then using opendir('Pictures'). But it still won't work.
The opendir() does not get executed correctly (I only proceed if it is correctly assigned) which I assume is due to the same reason as if I try to access the files directly.
The error it gives me when I try to reach the files directly http://localhost/Fontan/Pictures/afile.jpg
is access denied
I've tried adding the web group to the softlink (chown -h) and the real folder, set everything as executable and even set chmod 777 on all of it. But nothing works.
Any assistance would be much appreciated.