<virtualhost *:80>
ServerName www.pphp39.com
#设定该站点的“别" 即通过一下域名也可以访问
ServerAlias mip.php39.com
DocumenetRoot "文件路径"
<Directory “文件路径”>
oprions indexes
order deny,allow
Allow from all
#几乎不需要写deny
</Directory>
</virtualhost>
#第2个站点的配置
<virtualhost *:80>
ServerName www.guagua.com
DocumenetRoot "文件路径"
<Directory “文件路径”>
oprions indexes
order deny,allow
Allow from all
DirectoryIndex index3.html
</Directory>
</virtualhost>
#第3个站点的配置
<virtualhost *:80>
ServerName localhost
DocumenetRoot "文件路径"
<Directory “文件路径”>
oprions indexes
order deny,allow
Allow from all
</Directory>
#设置虚拟目录别名
Alias /soft “文件路径”
<Directory “文件路径”>
oprions indexes
order deny,allow
Allow from all
</virtualhost>