Develop your apps using Smarty 3 and PhpStorm

PhpStorm brings Smarty 3 PHP Template Engine power to its users.
First of all it supports Smarty syntax, highlights keywords, automatically closes tags and enables autocompletion of Smarty tags in template files:

Smarty syntax highlighting in PhpStorm IDE

The IDE handles language mixtures like HTML, JavaScript and PHP code inside Smarty templates. It not only highlights HTML inside Smarty, but even provides autocompletion:

Smarty autocompletion in PhpStorm IDE

as well as useful quick-fixes. As shown on the screenshot below, the IDE offers you to adjust the image size to its original height.


Another very useful feature is the Structure view where you can overview and navigate through your template structure.

Of course, you can set custom delimiters to avoid conflicts between standard Smarty delimiters “{ }” and javascripts brackets. For example, you may set delimiters for smarty like this: “<!–{”  :

Smarty custom delimiters

In addition to Smarty support, you also get many nice IDE features such as code folding/unfolding, PhpUnit support for your projects, refactorings, a Visual Debugger based on Xdebug or Zend Debugger, and best-in-class JavaScript editing support.

» Download stable PhpStorm 1.0 with basic Smarty support
» Download PhpStorm 2.0 Early Access Preview with full Smarty 3 support

Comments below can no longer be edited.

14 Responses to Develop your apps using Smarty 3 and PhpStorm

    • lera says:

      December 22, 2010

      We’ll put much effort on fixing most of the issues until the release of PHPStorm.

  1. Tank says:

    December 17, 2010

    Come on, follow your roadmap and update it frequently.

    I really need SASS 3 support, especially compilation support. And if you do HAML support, PHP-Storm will be the holy grail for pro front-end developers.

  2. Jason Gu says:

    December 17, 2010


    When will the next EAP be released?


  3. Rafi says:

    December 19, 2010

    Me and a lot of people stay away from Smarty. Have you thought about adding the Mustache format?

  4. yehosef says:

    December 19, 2010

    Second on the mustache support – the fact that I can write one template that can be used for php and Javascript (and ruby and java and…) is pretty attractive.

  5. Alexey Korsun says:

    December 20, 2010

    @Amal Samally
    Yes, we know. We are going to fix most of them in our 2.0 release which is planned at the end of January.

  6. Vladimie says:

    December 21, 2010

    End of January? Then please correct this “(Q4 2010)” in your development roadmap for PHPStorm. Thx.

  7. Cesa says:

    December 21, 2010

    It’s great to have support for Smarty.

  8. Alexey Korsun says:

    December 22, 2010

    Thank you, Vladimie. Corrected.

  9. Sam says:

    January 9, 2011

    Hi PhpStorm,

    How does one debug and set breakpoints in phpstorm when trying to debug smarty? i want to be able to debug it like how i am able to debug php, javascript, etc., being able to inspect the values of the variables, etc.

    thank you.

  10. Sinisa says:

    December 15, 2011

    I’m using lots of javascript inside my smarty template (I know I should do that). Can PhpStorm somehow detect this javascript (for autocompletition). The same problem is with CSS included in template file. It is, probably, not detected correctly and therefore the color boxes (really great help) are not displayed. Both Javascript and CSS is working correctly when inside CSS and JS separate file.

  11. rustam.vishnyakov says:

    December 16, 2011

    Normally JavaScript is detected inside “script” tag. If there is another way to add JavaScript code, PhpStorm may not detect it. So it depends on template.