Best Practices- HTML
A description of the concepts to consider for HTML in this XML editor.
SDL LiveContent Create needs valid XHTML in its output.The following considerations for HTML in SDL LiveContent Create can help you achieve this goal.
- Special characters need to be saved as they are, not as entities.
- SDL LiveContent Create needs valid XHTML output.
- Don't use <
legend> or <fieldset>
Entities and special characters
Entities, special characters and such, are best added as they are in UTF-8 encoding. Of course it impedes the searchability of the documents if you save them as HTML entities. For transport however it isn't an issue to save special characters as entities.
Valid XHTML
<div> in a <p> (<p><div></div></p>) Internet Explorer will assume a </p> closing tag before drawing the <div> (e.g.: <p></p><div></div>) because it cannot have a block level element in the paragraph. This means that your paragraph isn't <div> is rendered after the paragraph. The HTML will look like this:
<p></p>
<div>your text from the xml</div>
</p>
Don't use <legend> or <fieldset>
Well, that says it all really. Don't use those elements in your XSL output for SDL LiveContent Create HTML.