This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
en:otml [2023/03/17 17:36] – [User editable CSS] fw | en:otml [2025/02/27 11:01] (current) – bk | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== How to develop | + | ====== How do I develop |
- | The following document provides technical information for the development of e-mail | + | The following document provides technical information for the development of email templates for promio.connect. |
===== General information ===== | ===== General information ===== | ||
- | * Special characters must use XML conform entities: | + | * Special characters must use XML-conform entities: |
* ''& | * ''& | ||
* ''& | * ''& | ||
Line 13: | Line 13: | ||
* ''& | * ''& | ||
* ''& | * ''& | ||
- | * for all other entities you have to use decimal syntax; e.g.: use ''&# | + | * for all other entities, you have to use decimal syntax; e.g., use ''&# |
- | * UTF-8 4-byte characters are not supported at the moment. You can check the byte length with several tools, e.g. [[http:// | + | * UTF-8 4-byte characters are not supported at the moment. You can check the byte length with several tools, e.g., [[http:// |
* The length of lines in the source code **must not exceed 700 characters**. | * The length of lines in the source code **must not exceed 700 characters**. | ||
Line 35: | Line 35: | ||
===== OTML ===== | ===== OTML ===== | ||
- | OTML is an extension of the HTML standard, specifically created for usage in promio.connect' | + | OTML is an extension of the HTML standard, specifically created for usage in promio.connect' |
- | Because of this, an undestanding | + | Because of this, an understanding |
- | OTML serves the cause to make designated parts of an e-mail | + | OTML serves the cause to make designated parts of an email editable. The global structure of the email will not be affected. |
- | At first, the e-mail | + | At first, the email developer creates the email as usual. After this is done, all intended parts can be made editable with the usage of OTML. |
The OTML elements are separated into two namespaces: '' | The OTML elements are separated into two namespaces: '' | ||
- | * '' | + | * '' |
- | * '' | + | * '' |
+ | ==== Editable Title ==== | ||
+ | If you want the user to be able to edit the title of the mail, add the attribute '' | ||
+ | |||
+ | === Example === | ||
+ | |||
+ | <code html> | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | <title editable=" | ||
+ | </ | ||
+ | < | ||
+ | <div> | ||
+ | <a href=" | ||
+ | Please click here if you can't read this E-Mail. | ||
+ | </a> | ||
+ | </ | ||
+ | ... | ||
+ | </ | ||
Line 53: | Line 72: | ||
A repeater element defines an area of repeating blocks and **must contain one or more ''< | A repeater element defines an area of repeating blocks and **must contain one or more ''< | ||
- | added to the e-mail | + | added to the email by the user via a selection list. |
The repeater element can hold one or more ''< | The repeater element can hold one or more ''< | ||
Line 59: | Line 78: | ||
^ Attribute ^ Type ^ Required ^ Description | ^ Attribute ^ Type ^ Required ^ Description | ||
- | | title | string | No | Title of the repeater. This is useful, if you use more than one repeater in your template. | | + | | title | string | No | Title of the repeater. This is useful if you use more than one repeater in your template. | |
Line 100: | Line 119: | ||
A layout is represented by the OTML tag ''< | A layout is represented by the OTML tag ''< | ||
- | A layout element contains a template, which can be added to the e-mail. It's a sub-element of the ''< | + | A layout element contains a template, which can be added to the email. It's a sub-element of the ''< |
added multiple times. | added multiple times. | ||
Line 126: | Line 145: | ||
- | ==== Repeatercontent | + | ==== Repeater content |
- | A repeatercontent | + | A repeater content |
- | The repeatercontent | + | The repeater content |
- | It's a sub-element of the ''< | + | It's a sub-element of the ''< |
to pre-fill a ''< | to pre-fill a ''< | ||
Line 165: | Line 184: | ||
A preheader is represented by the OTML tag ''< | A preheader is represented by the OTML tag ''< | ||
- | A preheader is the preview text which is shown beneath the sender in most e-mail | + | A preheader is the preview text which is shown beneath the sender in most email clients. |
- | During the build process of the e-mail, the content of the preheader element will be put directly after the ''< | + | During the build process of the email, the content of the preheader element will be put directly after the ''< |
tracking pixels provided by promio.connect will be embedded after the preheader. This way, there is no HTML source code visible to the | tracking pixels provided by promio.connect will be embedded after the preheader. This way, there is no HTML source code visible to the | ||
end-user. | end-user. | ||
Line 414: | Line 433: | ||
^ Attribute | ^ Attribute | ||
- | | text | Text that is visible in the e-mail | + | | text | Text that is visible in the email | |
| summary | | summary | ||
| organizerName | | organizerName | ||
- | | organizerEmail | E-mail | + | | organizerEmail | Email of the appointments organizer |
| dateTimeStart | | dateTimeStart | ||
| dateTimeEnd | | dateTimeEnd | ||
Line 477: | Line 496: | ||
==== External data sources ==== | ==== External data sources ==== | ||
- | External data sources make it possible to embed content from RSS feeds into an e-mail. | + | External data sources make it possible to embed content from RSS feeds into an email. |
The setup of external data sources is individually realized by promio.net GmbH. If you are interested in the usage, please contact our support team via ticket. | The setup of external data sources is individually realized by promio.net GmbH. If you are interested in the usage, please contact our support team via ticket. | ||
Line 499: | Line 518: | ||
A source item is represented by the OTML tag ''< | A source item is represented by the OTML tag ''< | ||
- | It serves as the connection between the e-mail | + | It serves as the connection between the email and the setup data source. |
^ Attribute | ^ Attribute | ||
| name | Yes | string | | name | Yes | string | ||
- | | refreshmode | Yes | string | + | | refreshmode | Yes | string |
Line 509: | Line 528: | ||
^ Value ^ Description | ^ Value ^ Description | ||
- | | build | Refresh data source on build of the e-mail. | | + | | build | Refresh data source on build of the email. | |
- | | refresh | + | | delivery |
Line 639: | Line 658: | ||
- | == Rendered | + | == Rendered |
<code html> | <code html> | ||
Line 738: | Line 757: | ||
==== External content ==== | ==== External content ==== | ||
- | '' | + | '' |
- | It is also possible to use this tag in the subject of an e-mail. | + | It is also possible to use this tag in the subject of an email. |
^ Attribute ^ Type ^ Required ^ Description ^ | ^ Attribute ^ Type ^ Required ^ Description ^ | ||
Line 748: | Line 767: | ||
=== Example === | === Example === | ||
- | As content of an e-mail: | + | As content of an email: |
<code html> | <code html> | ||
< | < | ||
Line 766: | Line 785: | ||
==== Automatic transformation from CSS to inline CSS ==== | ==== Automatic transformation from CSS to inline CSS ==== | ||
- | CSS from '' | + | CSS from a <style> |
- | Also, the CSS inlining only works on HTML elements with one selector. | + | For more details on the matter refer to the **cssinline** and **cssinlinetype** options in [[en:otml#config_tags]] |
- | + | ||
- | + | ||
- | === Example === | + | |
- | + | ||
- | <code html> | + | |
- | < | + | |
- | < | + | |
- | /******************* | + | |
- | * Working examples * | + | |
- | *******************/ | + | |
- | + | ||
- | .foo { | + | |
- | font-size: | + | |
- | line-height: | + | |
- | } | + | |
- | + | ||
- | .bar { | + | |
- | background-color: #fff; | + | |
- | } | + | |
- | + | ||
- | img { | + | |
- | border: 0; | + | |
- | } | + | |
- | + | ||
- | + | ||
- | / | + | |
- | * Non-working examples * | + | |
- | ************************/ | + | |
- | + | ||
- | .baz, .boz { | + | |
- | font-size: | + | |
- | } | + | |
- | + | ||
- | table td { | + | |
- | background-color: | + | |
- | } | + | |
- | </ | + | |
- | </ | + | |
- | < | + | |
- | / | + | |
- | * Working examples * | + | |
- | *******************/ | + | |
- | < | + | |
- | < | + | |
- | <td class=" | + | |
- | < | + | |
- | </ | + | |
- | </ | + | |
- | < | + | |
- | <img alt="" | + | |
- | </ | + | |
- | </ | + | |
- | + | ||
- | + | ||
- | / | + | |
- | * Non-working examples * | + | |
- | ************************/ | + | |
- | < | + | |
- | < | + | |
- | <td class=" | + | |
- | Lorem ipsum dolor sit amet | + | |
- | </ | + | |
- | </ | + | |
- | </ | + | |
- | </ | + | |
- | </ | + | |
==== User editable CSS ==== | ==== User editable CSS ==== | ||
Line 886: | Line 838: | ||
With the help of placeholders, | With the help of placeholders, | ||
- | You can access each user data field, if you place a '' | + | You can access each user data field if you place a '' |
- | A list of all universal | + | A list of all universally |
- | If custom placeholders are requried, please contact our support team via ticket. | + | If custom placeholders are requried please contact our support team via ticket. |
=== Example === | === Example === | ||
- | '' | + | '' |
If no gender is given, it will fall back to "Dear Sir or Madam," | If no gender is given, it will fall back to "Dear Sir or Madam," | ||
Line 938: | Line 890: | ||
==== Config Tags ==== | ==== Config Tags ==== | ||
- | Config tags make it possible to control the behaviour of the e-mail | + | Config tags make it possible to control the behaviour of the email editor. |
^ Attribute | ^ Attribute | ||
| cssinline | | cssinline | ||
- | | cssinlinetype | string | + | | cssinlinetype | string |
| storage | | storage | ||
| ignoreerror | | ignoreerror | ||
+ | |||
+ | === Example === | ||
+ | |||
+ | <code html> | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
Line 950: | Line 913: | ||
^ Value ^ Description | ^ Value ^ Description | ||
- | | legacy | + | | default |
- | | ng | Use the new CSS inliner. | + | | ng | Use the new, improved |
+ | |||
+ | The **default** CSS Inliner can only transform CSS for single, non-comma-separated selectors. | ||
+ | The **ng** ("next generation" | ||
+ | |||
+ | == Examples for the default CSS Inliner == | ||
+ | |||
+ | <code html> | ||
+ | < | ||
+ | < | ||
+ | / | ||
+ | * Working examples * | ||
+ | *******************/ | ||
+ | |||
+ | .foo { | ||
+ | font-size: | ||
+ | line-height: | ||
+ | } | ||
+ | |||
+ | .bar { | ||
+ | background-color: | ||
+ | } | ||
+ | |||
+ | img { | ||
+ | border: 0; | ||
+ | } | ||
+ | |||
+ | |||
+ | / | ||
+ | * Non-working examples * | ||
+ | ************************/ | ||
+ | |||
+ | .baz, .boz { | ||
+ | font-size: | ||
+ | } | ||
+ | |||
+ | table td { | ||
+ | background-color: | ||
+ | } | ||
+ | </ | ||
+ | </ | ||
+ | < | ||
+ | / | ||
+ | * Working examples * | ||
+ | *******************/ | ||
+ | < | ||
+ | < | ||
+ | <td class=" | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | < | ||
+ | <img alt="" | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | |||
+ | / | ||
+ | * Non-working examples * | ||
+ | ************************/ | ||
+ | < | ||
+ | < | ||
+ | <td class=" | ||
+ | Lorem ipsum dolor sit amet | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
=== Values for storage === | === Values for storage === | ||
^ Value ^ Description ^ | ^ Value ^ Description ^ | ||
- | |frame | + | |frame |
- | |shadow | Save the contents from a shadow copy of the e-mail. This assures that the e-mails | + | |shadow | Save the contents from a shadow copy of the email. This assures that the email' |
- | === Example === | ||
- | <code html> | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | </ | ||
{{tag> OTML Templates }} | {{tag> OTML Templates }} | ||
+ |