1. Open the Modify/etc/apache2/httpd.conf content and look for the following:
[HTML] View plain copy documentroot "/library/webserver/documents" <Directory " Library/webserver/documents "> # # Possible values for the Options directive are "None", "All", # or any combination of: # indexes includes followsymlinks symlinksifownermatch execcgi MultiViews # # note that "MultiViews" must be named *explicitly* --- "options all" &NBSP;&NBSP;&NBSP;&NBSP;#&NBSP;DOESN ' t give it to you. # # the options directive is both complicated and important. please see # http://httpd.apache.org/docs /2.4/mod/core.html#options # for more information. # options followsymlinks multiviews MultiviewsMatch Any # # allowoverride controls what directives may be placed in .htaccess files. # it can be "All", "None", or any combination of the keywords: # AllowOverride FileInfo AuthConfig Limit # AllowOverride None &NBSP;&NBsp; # # controls who can get stuff from this server. # require all granted </Directory> original Apache root directory is/library/webserver/ Documents, which are changed to/users/username/phpsites, are as follows:
[HTML] view plain copy documentroot/users/username/phpsites <Directory/Users/username/phpSites> Options Indexes MultiViews # Apache 2.2 # allowoverride All # order Allow,deny # allow from 127.0 .0.1 # Apache 2.4 Require Local </Directory>
Apache Run Command:
sudo apachectl start//start
sudo apachectl restart//reboot
sudo apachectl stop//Stops