What is Index of / and how to disable Page Indexing
Posted by - NA - on 03 March 2007 02:27 PM
|
|
How to prevent directory listing You can turn off or change your indexing rules via your hosting control panel. Linux with cPanel: 2. Click the Index Manager icon, under the Advanced section 3. A Directory Selection option will normally pop-up. I recommend you choose the second option, Document Root for:, and then select the correct website from the dropdown. Then click the Go button. 4. Now you must select the correct folder. I recommend you click the first folder link immediately to the left of (Current Folder). Sometimes this will be public_html but it could instead be a subfolder, especially for Addon Domains and Subdomains. 5. There are a a few different options for choosing the way indexes are displayed, however if you wish to turn indexes off altogether, simply select No Indexing and press Save. Windows with ASP: 1. Login to your WebSitePanel (usually cp.domain.com) 2. Go to the Web icon and click Web Sites. 3. Click the name of your website and allow some time for the website properties to load. 4. Once the screen loads, uncheck the box for Enable Directory Listing and click the Update button at the bottom.
Why am I seeing Index of / ? If you ever see Index of / instead of your website, this is because the home page is not defined or not found. What? The home page is the first page all visitors see when they go to your website. Linux with cPanel: Normally, this is index.html or index.php; the names are case-sensitive, so Index.html will not be recognized. Sometimes you may want to use a different name, like Index.html or home.htm or page1.php; in that case, you will need to add a line of code to the very top of your .htaccess file. Here is the code to make example.ext the home page. DirectoryIndex example.ext Windows with ASP: Normally, this is Default.aspx or index.html; the names are not case-sensitive, so INDEX.HTML is also recognized, automatically. Sometimes you may want to use a different name, like home.aspx or index.php; in that case, you will need to add that name to the top of the list in your Website Properties: Default Documents list. Here is an example which makes example.ext the home page. Advanced: You can have more than one file name in the list. The website will go through the list from first to last, and the first page which is found will be used. This is helpful in case you are testing different web designs or want a specific page displayed when you take your site offline. | |
|