xsl-list
[Top] [All Lists]

[xsl] generic formula for splitting mixed-text elements to create blocks

2016-03-11 17:19:17
Is there a generally accepted way to split a mixed text element such as
<para>this is text with <bold>inline elements</bold> and includes a
   <list>
      <list-item><p>item a</list-item>
      <list-item><p>item b</list-item>
      <list-item><p>item c</list-item>
   </list>
within a paragraph with other inline elements <italic>after</italic> the
list/</para>

The result would be split to become this:
<para>this is text with <bold>inline elements</bold> and includes a</para>
<list>
   <list-item><p>item a</list-item>
   <list-item><p>item b</list-item>
   <list-item><p>item c</list-item>
</list>
<p>within a paragraph with other inline elements <italic>after</italic> the
list.</para>

I'm not terrible fold of splitting paragraphs, but for conversion to HTML,
the 2nd example is a better starting point for a transformation.

I'd like to have a pattern I could apply whenever I come across a similar
situation.
--~----------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
EasyUnsubscribe: http://lists.mulberrytech.com/unsub/xsl-list/1167547
or by email: xsl-list-unsub(_at_)lists(_dot_)mulberrytech(_dot_)com
--~--
<Prev in Thread] Current Thread [Next in Thread>