Wamp How to change the site root directory DocumentRoot
Presumably a lot of people use Wamp to develop PHP Web applications, and in some cases we may need to modify the root directory of the server to facilitate our construction and development of the site, next we will explain how to change the root directory of Wamp.
A total of 3 places to change
The first step, Open a wamp/scripts/config.inc.php file and find $wwwdir = $c _installdir. ' /www '; modified to: $wwwDir = ' x:/xx ';
Step Two, Modify the Apache default root directory, open Apache configuration file httpd.conf, set DocumentRoot "d:/wamp/www/" to DocumentRoot "x:/xx/", at the same time set to.
Then restart Wamp and then go to the Address bar to enter localhost to see it.
Note: 1, many students may forget to set up the config.inc.php file, please also note. One of the problems I encountered is that if you do not modify this, PHP error_log file (TXT) will increase dozens of K per second, very scary.
2, if you set up a virtual host, then the simplest way is to turn it off, because most of the virtual host configuration file will set the virtual map of localhost, of course, you can also set the virtual map as a new x:/xx/directory.
1:wamp How to change the Web site root directory documentroot 2:php error_log file (TXT) will increase by dozens of K/s