View Single Post
Old 04-02-2014, 02:56 PM   #590
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
Quote:
Originally Posted by Rev. Bob View Post
The problem is, your regex still isn't doing what it would need to do. The challenge is to remove a specific set of SPANs, namely those matching the form
Code:
<span class="koboSpan" id="kobo.2.1">content</span>
...regardless of whether the content itself has SPANs.
Since I don't have a Kobo, I was merely suggesting general methods of hunting spans.

Quote:
Originally Posted by eschwartz View Post
Final regex:
Code:
<span[^<>]*>((?:(?!<(?:span|/span)).)*)</span>
Can be edited to fill in any required classes/ids with ease :

Code:
<span{ kobo-specific info goes here}[^<>]*>((?:(?!<(?:span|/span)).)*)</span>

Last edited by eschwartz; 04-02-2014 at 03:06 PM. Reason: (classes) or ids
eschwartz is offline   Reply With Quote