# Edit and test document templates

Find the document in System Management, then Document Templates. Before editing a shared template, identify where it is used and preserve its current version. Work on an isolated inactive example while reviewing a change. Here, Training Service Review Letter is a separate template with Active set to No. Check its type, application, Agency and Company scope, and transmission settings. A letter, a package document, and an included template have different purposes. Review any task hooks or recipients before making a template available for use.

Edit Template Data using HTML and Smarty. The built-in editor supports direct source editing, and Open in IDE provides the larger code workspace. In this example, the greeting uses the client's first-name variable, with an escape modifier for text output. The message asks the client to review contact information and prepare questions for the counselor. Save the change with Update. Keep wording short and specific, and use template variables only where they supply verified record information. A source edit still needs a rendered preview.

Preview the template with an appropriate test client. The browser preview resolves the greeting to Hello Casey and displays the requested action. Check names, conditional sections, spacing, and links against the intended result. Browser preview is one output: a PDF or email also needs review in its own delivery format. Use Validate Templates for the complete supported Smarty and browser-policy checks; Validate CSP checks stored source for browser-policy issues only. Review failures and skipped templates explicitly. A successful validation does not replace reading the final document.

Use History and Compare to review a saved revision against the current working copy. Here, the comparison highlights the added sentence stating that no message has been sent. Confirm that the difference is intentional before saving or restoring content. After any restoration, save the new version and repeat preview and validation. Finally, confirm the approved scope and delivery behavior before activation. Retain the template ID, revision, test client, and review result so the next update can be checked without reconstructing the original work.