{"id":9846,"date":"2009-10-26T14:06:07","date_gmt":"2009-10-26T18:06:07","guid":{"rendered":"https:\/\/www.bu.edu\/tech\/?page_id=9846"},"modified":"2013-03-13T17:02:32","modified_gmt":"2013-03-13T21:02:32","slug":"email-templates","status":"publish","type":"page","link":"https:\/\/www.bu.edu\/tech\/services\/cccs\/websites\/people\/forms\/form-to-email\/email-templates\/","title":{"rendered":"Email Templates"},"content":{"rendered":"<p>In order to format emails or web pages created by PonyExpress,                   you will create separate template files. There are two types of                   templates used with PonyExpress: email templates and file templates.<\/p>\n<p>All the templates are plain text files, so if you create them in                   more advanced word processors like MS Word, make sure to save them                   as plain text. Also, since Windows applications may append file extensions                   invisibly, <strong>make sure you rename the file<\/strong> once it is on the server                   so that it does not have any three-letter extension (e.g., .txt).<\/p>\n<h2>.message templates<\/h2>\n<p>The admin.message template is used to format the email message                   sent to the form owner. Without this template, email will be sent                   as a list of form fields and their values, whereas the template                   allows you to format the message any way you wish. Similarly, the                   visitor.message template formats mail sent to the person filling                   out the form. The <strong>visitor.message template is required<\/strong> if you wish to reply to the                   visitor; these replies cannot be sent as unformatted lists.<\/p>\n<p>In both templates, you simply compose the message as you want it                   to appear. This will look exactly like the sent message, with one                   important exception: any variable names you include in square brackets                   [ ] will be substituted with the corresponding variables from your                   form. For example:<\/p>\n<blockquote><p><strong><span>[fullname] <\/span><\/strong><span>submitted                     the following information:<\/span><strong><span><br \/>\n[phone]<br \/>\n[address1]<br \/>\n[address2]<br \/>\n[city], [state] [zip]<\/span><\/strong><\/p>\n<p><span>He\/she has ordered <\/span><strong><span>[amount]                     [product]<\/span><\/strong><span>(s), and will pay                     by <\/span><strong><span>[payment_method]<\/span><\/strong><span>.<\/span><\/p><\/blockquote>\n<p>Once a visitor has filled out the form using this hypothetical template,                   the form owner would receive the following email:<\/p>\n<blockquote><p>John Smith submitted the following information:<br \/>\n617-555-1234<br \/>\n13 Nowhere Ln.<br \/>\nAPT #4<br \/>\nBoston, MA 02234<\/p>\n<p>He\/she has ordered 7 tumbleweed(s), and                     will pay by check.<\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>In order to format emails or web pages created by PonyExpress, you will create separate template files. There are two types of templates used with PonyExpress: email templates and file templates. All the templates are plain text files, so if you create them in more advanced word processors like MS Word, make sure to save&#8230;<\/p>\n","protected":false},"author":1685,"featured_media":0,"parent":9811,"menu_order":2,"comment_status":"closed","ping_status":"closed","template":"","meta":[],"_links":{"self":[{"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/pages\/9846"}],"collection":[{"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/users\/1685"}],"replies":[{"embeddable":true,"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/comments?post=9846"}],"version-history":[{"count":8,"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/pages\/9846\/revisions"}],"predecessor-version":[{"id":33884,"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/pages\/9846\/revisions\/33884"}],"up":[{"embeddable":true,"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/pages\/9811"}],"wp:attachment":[{"href":"https:\/\/www.bu.edu\/tech\/wp-json\/wp\/v2\/media?parent=9846"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}