Using a temporary DocumentRoot without modifying apache configurationIf you want to test the working of a website without modifying the httpd.conf file and original files under the default DocumentRoot, do the following.
Take a copy of your original DocumentRoot directory (/var/www/html) to a new temporary DocumentRoot directory (/var/www/html_debug). Make all your changes under this temporary DocumentRoot directory (/var/www/html_debug) and start the Apache with this temporary directory as shown below using option -c.
httpd -k start -c "DocumentRoot /var/www/html_debug/"If you want to go back to original configuration using the default DocumentRoot (/var/www/html), simply restart the Apache as shown below.
# httpd -k stop
# apachectl startDone...