How does the server know that the index is the main page?

3

For example, I have several .HTML and .PHP files in the public_html folder on my server (Internal), but when opening the path in the browser (open the path link ), it always opens the index.html, instead of opening the little files (I mean, list all the files / folders that we have inside the public_html) to choose which page we want to open.

Why this? Is it standard?

    
asked by anonymous 29.06.2017 / 14:07

2 answers

5

In general this is Apache's default, but you can change this in the file .htaccess

<Directory /var/www/>
    Options Indexes FollowSymLinks MultiViews
    AllowOverride None
    Order allow,deny
    allow from all
</Directory>
    
29.06.2017 / 14:15
0

Yes, it is standard. Depending on your web server, you can define what the default document is in the settings, or in ASP.NET for example, define this by the web.config file as well

    
29.06.2017 / 14:11