【发布时间】:2019-12-15 18:22:26
【问题描述】:
我在服务器 pc 上有一个 laravel 项目,我想使用连接在同一网络上的其他 pc 访问它,而不在服务器 pc 上运行 php artisan serve。
我尝试使用虚拟主机,它在服务器 pc 上工作,但在网络上的其他 pc 上得到这个错误页面 laravelproject.test 的服务器 IP 地址找不到。
<VirtualHost *:80>
ServerAdmin webmaster@dummy-host2.example.com
DocumentRoot "D:\xampp\htdocs\247_timesheet\public"
ServerName timesheet.test
ErrorLog "logs/timesheet.test-error.log"
CustomLog "logs/timesheet.test-access.log" common
</VirtualHost>
主机文件
127.0.0.1 timesheet.test
【问题讨论】: