1.首先关闭windows防火墙
2.打开Apache配置文件 httpd-vhosts.conf
# Virtual Hosts
#
<VirtualHost 192.168.1.131:80> //修改为本机的ip
ServerName localhost
ServerAlias localhost
DocumentRoot "e:/wamp/www/new" //修改为对应的文件目录
<Directory "${INSTALL_DIR}/www/">
Options +Indexes +Includes +FollowSymLinks +MultiViews
AllowOverride All
#Require local
Require all granted //修改为允许所有
</Directory>
</VirtualHost>
#
#
<VirtualHost *:80>
ServerName jojo.com
DocumentRoot "e:/wamp/www/new"
<Directory "e:/wamp/www/new/">
Options +Indexes +Includes +FollowSymLinks +MultiViews
AllowOverride All
#Require local
Require all granted
</Directory>
</VirtualHost>
3.打开httpd.conf配置文件
将: Require local->修改为
Require all granted
4.重启所有服务
即可在同一局域网下使用ip访问服务器