找到設置中的文件設置中的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代碼了


