Generally, the root directory of the website is the direct default home page when we create a website by default, but some programs may need to be set in other secondary directories as the default home page directory. Today, Lao Zuo encountered this situation when debugging a program. The server uses the pagoda panel, and the WEB environment is Apache. Here you need to find the configuration file of the corresponding site to modify it. The pagoda panel should have moved the default configuration file.
First, configuration file address
/www/server/panel/vhost/apache
If the pagoda panel is used, it is the domain name conf file of the corresponding website under this address. If it is other WEB environments, it depends on whether they have moved. We can use the find command to find out.
Second, modify the default directory
There are two default directories. We can add folders according to the default path we need.
Third, restart Apache
/etc/init.d/httpd restart
Then restart Apache to take effect.
Scan the code to follow the official account
Get more news about webmaster circle!
Entrepreneurship, operation and new knowledge