vscode中让html中php代码高亮


找到设置中的文件设置中的files.associations,增加以下内容(注意一下内容要放在右侧的用户设置中,而不是放在中间的默认设置中):

{

// Configure file associations to languages (e.g. "*.extension": "html"). These have precedence over the default associations of the languages installed.

"files.associations": {"*.html": "php"}

}

这样就可以在扩展名为html的文件中识别PHP代码了

 

 

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM