block direct directory access in PHP ?

The safest way is to put the files you want kept to yourself outside of the web root directory, like Damien suggested. This works because the web server follows local file system privileges, not its own privileges.
However, there are a lot of hosting companies that only give you access to the web root. To still prevent HTTP requests to the files, put them into a directory by themselves with a .htaccess file that blocks all communication

Top Astrology Services in Toronto | Top Indian Astrologer in Toronto | Indian Astrologer in Toronto | Best Indian Astrologer in Toronto | Indian Astrologer in Canada | Best Astrologer in Canada
 
Back
Top