sudo systemctl restart apache2 Create a file named .htaccess inside the folder containing private images and add:
<Directory /var/www/html> Options -Indexes </Directory> The minus sign ( -Indexes ) disables directory listings. Restart Apache: parent directory index of private images install
Options -Indexes Then upload it to the directory. If you want to block all access to the folder entirely, use: sudo systemctl restart apache2 Create a file named