views:

8

answers:

0

hey guys, i know it's rather easy to pass-protect a directory on my server with .htaccess and a .htpasswd file.

however is it possible to protect just a file from beeing executed?

e.g. i had something like a backend direcotry on my server with a normal index.php in it. now i got rid of the directory and i have a backend.php in my root directory.

is it possible to ask for a username and password before the backend.php file get's executed?