Vscode: Emmet support for PHP

Created on 20 Sep 2016  路  16Comments  路  Source: microsoft/vscode

  • VSCode Version: 1.5.2
  • OS Version: Ubuntu 16.04

Steps to Reproduce:

I will like to emmet works in php! ;)

feature-request needs more info

Most helpful comment

Will the emmet.syntaxProfiles setting help you? You can associate Emmet profiles like "html" and "css" with a language identifier.

{
"emmet.syntaxProfiles": {
"php": "html"
}
}

All 16 comments

Will the emmet.syntaxProfiles setting help you? You can associate Emmet profiles like "html" and "css" with a language identifier.

{
"emmet.syntaxProfiles": {
"php": "html"
}
}

Emmet should work with PHP without settings in VS Code above 1.5.0 version. May be you have file.associations or emmet.exclude? You can provide your settings?

Thanks !! :D @gregvanl

@heckctor Does this solve the issue for you?

@chrmarti Yes, thanks!

From VS Code 1.15 onwards, no setting is needed to get Emmet to work in php files.

@ramya-rao-a its not working for me thou , I'm on 1.15 ( ubuntu ) ;
tegs expand but not classes or ids .. etc

@gregvanl where do I add that ?

@a-eid I think the problem is that emmet is not getting activated yet...

Can you open an html file and then go back to your php file and try again?

@ramya-rao-a "php.suggest.basic": false resolved the problem.

@ramya-rao-a

whenever I try type something (.class for example) that contain an operator (minus sign) (col-md-8) or a number it doesn't trigger emmet . the php drop down suggestion appears and pressing tab triggers <?php


how to fix that ?

That's a suggestion from the php-language-server by @felixfbecker and there's no way to get rid of that suggestion, yet.

@a-eid

Turns out the issue is not just with the - sign. Any emmet abbreviation with class operator doesnt seem to show up in the suggestions. I have logged #32423 for it.

I also noticed that the ordering of emmet suggestions is different in php. Logged #32424 for that

@a-eid if you put a . at the final it works.

.col-md-8. (tab)

Inside of vscode it is ".." instead of a single "."

Hi, please translate this message to English Jeje

Al actualizar Visual Studio Code no pod铆a auto-completar etiquetas HTML en archivos .php (en Laravel, archivos .php - Blade), para solucionar esto cambie lo siguiente:

"emmet.triggerExpansionOnTab": true (antes estaba en "false")

Was this page helpful?
0 / 5 - 0 ratings

Related issues

lukehoban picture lukehoban  路  3Comments

NikosEfthias picture NikosEfthias  路  3Comments

vsccarl picture vsccarl  路  3Comments

biij5698 picture biij5698  路  3Comments

VitorLuizC picture VitorLuizC  路  3Comments