Write and edit source codeLive templatesWrapping a Tag. Example of Applying Surround Live TemplatesWrapping a Tag. Example of Applying Surround Live Templates Last modified: 08 March 2021As an example of applying a surround template, let's wrap a piece of XML code with tags. To surround a code fragment Open the desired file for editing.Select a code fragment. Press invocation shortcut Ctrl+Alt+J. PhpStorm suggests the following surround templates: Select the tag template from the suggestion list. The code fragment is surrounded with empty tags: The caret rests within the opening one. On typing the tag name in the opening tag, the name is automatically reproduced in the closing tag: Thanks for your feedback!Was this page helpful?YesNo