Batch composition to HTML

When using an XML-sensitive browser to display an XML document, it is only necessary to create a suitable CSS stylesheet, and reference it from the document. But when using an HTML-sensitive browser to display an XML document, a software 'filter' is used to transform the document into HTML format.



When using a filter program (or XSLT stylesheet), HTML in-line styles become a practical, and sometimes preferred, option. A filter program does not object to repeatedly generating the same style rule, it simply adds the Style attribute directly to each element:

<p style="font-size: 9pt ; color: blue">...</p>
<p style="font-size: 9pt ; color: blue">....</p>
<p style="font-size: 9pt ; color: blue">.....</p>

Although in-line styles were originally intended for 'tweaking' the appearance of specific objects on design-centred Web pages, the advantage of this approach is the total flexibility it provides. The filter software is able to take complex element and attribute value-based context rules into consideration when determining the style of each HTML element.

For example, the content of a Person element may need to be presented in different colours, according to some age grouping category, such as baby, toddler, child, teenager, adult and pensioner, for which appropriate age ranges are assigned, but working from an Age attribute that contains a simple value such as '36'. The software would supply the appropriate colour value using a look-up table of age ranges.

The disadvantages of this approach are the need for an intelligent filter program, and the larger size of the resulting HTML document.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.189.14.219