Skip to main content
small text fix
Source Link
Mad Dog Tannen
  • 7.3k
  • 5
  • 34
  • 55

Disallow direct access to a file in htaccess?

I would like to disallow users to access directly to a PHP script on my website. 

This script should instead be accessed from other scripts on the website. 

For example, "somepage.php" can call "upload.php", but users are not allowed to type "mywebsite.com/upload.php"mywebsite.com/upload.php. Unfortunately I can't move my script to a specific folder.

Thanks in advance.

Disallow direct access to a file in htaccess

I would like to disallow users to access directly to a PHP script on my website. This script should instead be accessed from other scripts on the website. For example, "somepage.php" can call "upload.php", but users are not allowed to type "mywebsite.com/upload.php". Unfortunately I can't move my script to a specific folder.

Thanks in advance.

Disallow direct access to a file in htaccess?

I would like to disallow users to access directly to a PHP script on my website. 

This script should instead be accessed from other scripts on the website. 

For example, "somepage.php" can call "upload.php", but users are not allowed to type mywebsite.com/upload.php. Unfortunately I can't move my script to a specific folder.

Source Link
Giorgio
  • 2k
  • 6
  • 41
  • 70

Disallow direct access to a file in htaccess

I would like to disallow users to access directly to a PHP script on my website. This script should instead be accessed from other scripts on the website. For example, "somepage.php" can call "upload.php", but users are not allowed to type "mywebsite.com/upload.php". Unfortunately I can't move my script to a specific folder.

Thanks in advance.