Jump to content

Recommended Posts

Hi, I didn't know which forum to post this in, so I just came here.

 

Does anyone know how to block web folders from people seeing the contents.

Example: Someone goes to "www.mysite.com/FolderName/" they would be able to see all the content of that folder.

 

I know you can put an index file in the folder to have it load that when they go to that folder, but is there a way to block it without adding the index?

 

I also tried to chmod the folder only to 750, but that blocked all the content in the folders to.

 

If anyone knows if this is possible and how to do it please let me know! Thanks :)

Link to comment
https://forums.phpfreaks.com/topic/46076-blocking-web-folders/
Share on other sites

make a index file

ie index.php or index.html

 

when they goto that folder it will show the page not the contains  ;)

 

I love people that don't read the entire post before responding. 

 

And neylitalo, adding an .htaccess file takes just about as much work as adding index files.  If it's your webserver, look up the manual.  It will have an option to turn it off.  If it's not your webserver, check your control panel or ask the host how to modify the settings.

Link to comment
https://forums.phpfreaks.com/topic/46076-blocking-web-folders/#findComment-224576
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.