Subject: Re: Move elements to preceding parent
From: Martin Honnen <Martin.Honnen@xxxxxx>
Date: Wed, 17 Jun 2009 15:16:18 +0200
|
Israel Viente wrote:
Required output:
<?xml version="1.0" encoding="UTF-8"?>
<html xmlns="http://www.w3.org/1999/xhtml">
<body>
<p dir="rtl">
<span class="chapter">line1</span>
</p>
<p dir="rtl">
<span class="regular">line10</span>
<span class="regular">line11</span>
<span class="regular">line12</span>
<span class="regular">line13.</span>
</p>
<p dir="rtl">
<span class="regular">line14</span>
<span class="regular">line15</span>
<span class="regular">line16.</span>
</p>
<p dir="rtl">
<span class="regular">line17"</span>
</p>
</body>
</html>
I think the solution posted by Ken Holman on 2009-06-14 does what you
want, even for the more complex input you have now shown.
--
Martin Honnen
http://msmvps.com/blogs/martin_honnen/
|