<!DOCTYPE> auto complete!

hello .

in other IDE like VSCode when i type html suggested html5 when i click or TAB default html format inset in my page like : 

phpstorm have this option? when i type <html and TAB fill lie this code?

<!DOCTYPE html>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Page Title</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" media="screen" href="main.css" />
<script src="main.js"></script>
Comment actions Permalink

Hi there,

Yes, PhpStorm supports Emmet abbreviations, implemented using Live Templates.

Just type ![TAB] (for generic one) or html:5[TAB] for HTML 5 one etc.

You can check & edit all available Live Templates at "Settings/Preferences | Editor | Live Templates", HTML ones can be found under "Zen HTML" group.

Comment actions Permalink

Andriy Bazanov tnx a lot :) you are amazing . i inserted this live template in PHP :)  but doesn't work  in html files too !!!! i know  im so noob! :)) but i want to fix and learn . tanx for helping.

Comment actions Permalink

1) Check help pages first -- how it works etc: https://www.jetbrains.com/help/phpstorm/creating-and-editing-live-templates.html

2) Why do you need it in PHP ... if it's a HTML code?

3) Have a look at your screenshot -- it shows "No applicable contexts" warning (at the bottom; your GUI theme makes it not so obvious/not standing out). Refer to #1.


P.S. Using "<!DOCTYPE html>" as abbreviation is questionable IMO (inconvenient). You will realise that once you figure out how it all actually works (e.g. just "doctype" is more convenient to type).

Comment actions Permalink

helpful:) thank you so much. for another help.


Please sign in to leave a comment.