Title: hide directory structure
Last modified: August 19, 2016

---

# hide directory structure

 *  Resolved [leandrocc](https://wordpress.org/support/users/leandrocc/)
 * (@leandrocc)
 * [16 years, 7 months ago](https://wordpress.org/support/topic/hide-directory-structure/)
 * Hi everyone,
 * I have my blog on [http://www.mydomain.com](http://www.mydomain.com) and files
   I upload to use there go on directories like [http://www.mydomain.com/wp-content/2009/11/filename](http://www.mydomain.com/wp-content/2009/11/filename).
 * If a user notice that and copy this link, they have direct access to the file.
   But if he/she erases the /filename, then they’ll get access to all files, including
   ones not used in any posts yet, and maybe never to be used.
 * Question: Is there an easy way NOT to display this directory style page, and 
   return to the main page (or any other one) ?

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [MichaelH](https://wordpress.org/support/users/michaelh/)
 * (@michaelh)
 * [16 years, 7 months ago](https://wordpress.org/support/topic/hide-directory-structure/#post-1271783)
 * Could copy the index.php from wp-contents folder into each of those sub-folders.
 * Essentially that file is a php script that does nothing
 *     ```
       <?php
       // Silence is golden.
       ?>
       ```
   
 *  [MichaelH](https://wordpress.org/support/users/michaelh/)
 * (@michaelh)
 * [16 years, 7 months ago](https://wordpress.org/support/topic/hide-directory-structure/#post-1271786)
 * Or this .htaccess trick which I just tried in the uploads folder
 *     ```
       # Don't allow directory browsing
       Options All -Indexes
       ```
   
 *  Thread Starter [leandrocc](https://wordpress.org/support/users/leandrocc/)
 * (@leandrocc)
 * [16 years, 7 months ago](https://wordpress.org/support/topic/hide-directory-structure/#post-1271826)
 * thanks a lot!

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘hide directory structure’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 3 replies
 * 2 participants
 * Last reply from: [leandrocc](https://wordpress.org/support/users/leandrocc/)
 * Last activity: [16 years, 7 months ago](https://wordpress.org/support/topic/hide-directory-structure/#post-1271826)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
