Yes, we all want to save our files and documentation from system crash of C Drive. To avoid this issue we generally locate our “WWW” or “htdocs” directory in different location from the default installation directory i.e. C Drive.
So it’s very easy to change the “WWW” directory in latest WampServer 3 that comes with PHP 5.6 , 7.x , MySQL as well as MariaDB.
- Click on WampServer icon in right side bottom taskbar
- Select the Apache menu -> httpd-vhosts.conf from the Pullup menu box.
- Search (
CTRL + F)for the term “DocumentRoot”
- Change the DocumentRoot path
to your custom directory e.g.
- Save your changes and “Restart All Services”
When you browse to
http://localhost, before the directory change the localhost window looks like this one.
And after the change for directory the localhost window looks like this one.