Quote:
Originally Posted by AlanHK
I've got a book file full of code like :
Code:
<p class="calibre2"><span class="none2">blah blah blah</span></p>
Is there a way I can remove these spans, (the "none2" ones) to get
Code:
<p class="calibre2">blah blah blah</p>
without messing up any other spans?
I can remove the opening by simple s&r, but then I would have orphaned </span>, but could not just delete </span> without screwing up other spans.
|
Well as others have mentioned, solved this now.
1) Neuter the unwanted spans (convert to <span>) in Sigil or calibre code editor
2) Run it through the calibre plugin "Modify ePub"
https://www.mobileread.com/forums/sho...d.php?t=154371
applying "HTML/Strip spans", which removes that and other null tags.
Quote:
|
Originally Posted by "Modify ePub help"
Strip spans
Removes empty formatting elements (ie. <i/> or <b></b>) and SPAN elements that have no attributes.
This also converts empty container elements into self-closing elements (ie. <br></br> becomes <br/>).
|