使用php为本地html文件生成url

1. 查看你是不是有php

   which php

2.  假设你的Demo.html 路径为 /Users/Sheron/Downloads/Demo.html 

   

cd /Users/Sheron/Downloads/
php -S localhost:8080

3.  在浏览器打开 https://localhost:8080/Demo.html 就可以了

 

 

posted @ 2020-07-13 20:25  Xylophone  Views(381)  Comments(0Edit  收藏  举报