View Single Post
Old 03-05-2016, 12:43 AM   #1037
Rev. Bob
Wizard
Rev. Bob ought to be getting tired of karma fortunes by now.Rev. Bob ought to be getting tired of karma fortunes by now.Rev. Bob ought to be getting tired of karma fortunes by now.Rev. Bob ought to be getting tired of karma fortunes by now.Rev. Bob ought to be getting tired of karma fortunes by now.Rev. Bob ought to be getting tired of karma fortunes by now.Rev. Bob ought to be getting tired of karma fortunes by now.Rev. Bob ought to be getting tired of karma fortunes by now.Rev. Bob ought to be getting tired of karma fortunes by now.Rev. Bob ought to be getting tired of karma fortunes by now.Rev. Bob ought to be getting tired of karma fortunes by now.
 
Rev. Bob's Avatar
 
Posts: 1,760
Karma: 9918418
Join Date: Feb 2013
Location: Here on the perimeter, there are no stars
Device: Kobo H2O, iPad mini 3, Kindle Touch
Quote:
Originally Posted by BetterRed View Post
So my question is, can Modify be adjusted to remove these unreferenced spans.
The problem with that IDea* is that Modify doesn't build a table of IDs such that it can look and see which ones get referenced and which don't. It's an in-the-moment tool, not a holistic one, and this is one of the shortcomings of that approach. Since removing referenced spans would be A Very Bad Thing for navigation, the only remaining practical option Modify has is to assume that ID attributes are significant and must be preserved.

I run into a similar situation all the time with CSS classes. As a result, sometimes I end up running my "cleanup" script (applying Modify with a certain profile, including strip-spans) multiple times while processing a particularly obnoxious book. It's annoying, but there's really no help for it.

* Hee. Cheap puns are fun.
Rev. Bob is offline   Reply With Quote