X

An Oracle blog about NetBeans for PHP

Smarty: Configurable Comments and Code Templates

Hello, today we would like to show you few improvements we have
prepared in PHP Smarty Framework for NetBeans 7.3. So let's talk about adjustable toggle comment action and code templates.

Configurable Comments

As some of you requested we implemented toggle comment action with adjustable behavior. In NetBeans 7.3 you can choose in Options between commenting as a "Smarty comments everywhere" or "Language sensitive comments" in Smarty Templates.

Configurable Comments in Options

Toggle comment language sensitive:

Toggle comment as Smarty comment everywhere:


Code Templates

In NetBeans 7.3 we will provide by default many code templates inside Smarty templates or directly inside Smarty tags. Available should be code templates for all built-in or custom functions and modifiers of Smarty 3.x. Besides that you should be able to define additional custom templates easily in Options -> Editor -> Code Templates for "Smarty Templates" or directly for "Smarty Markup" (which means code templates inside Smarty tag).

You can also take advantage of selection's template which are able to wrap your code with chosen Smarty tag.

That's all for today. As always, please test it and report all the issues or enhancements you find in NetBeans BugZilla (component php, subcomponent Smarty).

Join the discussion

Comments ( 3 )
  • Tom Monday, August 27, 2012

    Since I was among the guys who have asked for this and were awaiting this feature impatiently, all I can say is: thank you Martin! This is great news.

    I will give it a try. Great work!


  • Christian Wednesday, August 29, 2012

    What a pity that I don't use smarty ^^.

    It would be nice if you could provide the comment toggle function for Twig, too ;-)

    Thanks for your work!


  • Ondrej Brejla Friday, August 31, 2012

    Hi Christian,

    I have it in my ToDo list, so ;)


Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.