当前位置:网站首页>Vscode实现PHP在浏览器实时预览
Vscode实现PHP在浏览器实时预览
2022-06-12 23:47:00 【s3207】
大家在写html的时候能用到实时预览,但是在PHP就没法用了,虽然之前推荐过“Open PHP/HTML/JS In Browser”这个插件,可是没有实时预览这个功能,是非常难受的,然后我就翻阅互联网找到了一种解决方法。
那就是使用“Live Server”,也许你会说:“什么?这不是实时预览html的吗?你不是在开玩笑吧。”那我只能说是咱大家见识少了,我看见的第一瞬间也是不相信的,只是我发现了谷歌浏览器和火狐浏览器的这个插件。

就是“Live Server Web Extension”这个插件,谷歌浏览器和火狐浏览器才能下载。
(记得点击文字超链接下载)
2.配置插件。
首先我们把插件打开。

发现是这个一个界面,然后我们只需要简单的配置两个地址就可以了。

①“Actual Server Address”是你访问实际服务器的地址,就好比我前面教程中IIS配置的那个地址,也是你使用XAMPP什么的服务器地址,如图下图解释。

②“Live Server Address”是填写你使用插件右击,有一个"Open with live server",点击之后打开浏览器,上方地址,如图所示。
![]()
接下来我们打开Vscode找到Live Server,打开它的拓展,把下方给勾选上。
最后总结
1.我们先在浏览器下载好这个这个插件。
2.我们去配置这个插件的地址。最终效果如图。

3.我们打开Vscode中的 Live Server插件,打开它的拓展,勾选上,如图所示。

4.我们在浏览器中输入你的实际访问地址,如:http://localhost:1553/blog/index.php
配置好之后大家就可以打开浏览器来测试啦。
边栏推荐
- Ast, really fragrant
- Tableau
- 华为云弹性云服务器ECS使用【华为云至简致远】
- KConfig
- Opencv source code compilation
- Initial experience of Huawei cloud Conference [Huawei cloud to jianzhiyuan]
- How does idea switch the interface to Chinese
- 【Matlab】矩阵操作
- Start of u-boot S analysis (III)
- Examination questions and online simulation examination for safety management personnel of hazardous chemical business units in 2022
猜你喜欢

Is divicon still used in leaflet in H5 era?

2022年R2移动式压力容器充装考试题及在线模拟考试

Leetcode1601: the maximum number of building change requests that can be reached (difficult)

How to publish OSM maps locally and customize the mapping

如何让矢量瓦片配图神器maputnik支持 geoserver

leaflet中如何通过透明度控制layerGroup的显示隐藏

Redis realizes SMS verification code login

Based on three JS offshore wind power digital twin 3D effect

支持Canvas的Leaflet.Path.DashFlow动态流向线

OSM地图本地发布-如何生成各省市矢量地图
随机推荐
利率降低导致债券价格上涨
2022年危险化学品经营单位安全管理人员考试试题及在线模拟考试
Comprehensive analysis of C array
RT thread quick start - experience RT thread
It is meaningful to define genus, and D can use it to explain semantics
The most complete preview! Huawei cloud wonderful agenda collection
Divicon est toujours utilisé dans le leaflet de l'ère H5?
H5时代leaflet中还在用DivIcon?
Alien Skin Exposure X7调色滤镜插件,RAW后期处理工具
Alien skin exposure X7 color filter plug-in, raw post-processing tool
[issue 30] shopee golang development experience
测试平台系列(97) 完善执行case部分
你真的会用PostGIS中的buffer缓冲吗?
Actual combat | inductance element positioning -- detailed explanation of Halcon and opencv implementation (with source code)
Hongmeng starts 2
leaflet如何优雅的展示重叠点位的气泡窗口
Day 3 of jsbom and DOM learning
Theory + practice will help you master the dynamic programming method
How to publish OSM maps locally and customize the mapping
Online examination questions for September examination of financial management