05-11-2010, 10:33 AM | #1 |
eBook FANatic
Posts: 18,301
Karma: 16071131
Join Date: Apr 2008
Location: Alabama, USA
Device: HP ipac RX5915 Wife's Kindle
|
What's wrong with this regex?
This seems to be a pretty generic regex, but the Find/Replace dialog reports "The search term cannot be found." It works in EditpadPro so either the flavor must be wrong or I'm setting up the Find/Replace incorrectly. Regular expression is ticked.
<SPAN\s+class\s*=\s*pagenum>[^~]+?</SPAN> So many new things to learn. |
05-11-2010, 01:49 PM | #2 |
Created Sigil, FlightCrew
Posts: 1,982
Karma: 350515
Join Date: Feb 2008
Device: Kobo Clara HD
|
You are using non-greedy quantifiers (the "[^~]+?" part). As the manual states, that is not supported. Use the "Minimal matching" option. In time, the current regex engine will be replaced with PCRE which supports such constructs.
I really do suggest that people read the manual. |
Advert | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Sigil and Regex | crutledge | Sigil | 2 | 07-14-2010 04:51 PM |
What a regex is | Worldwalker | Calibre | 20 | 05-10-2010 05:51 AM |
Help with a regex | A.T.E. | Calibre | 1 | 04-05-2010 07:50 AM |
Regex help... | Bobthebass | Workshop | 6 | 04-26-2009 03:54 PM |
Need help with regex expression | daesdaemar | Workshop | 18 | 02-07-2009 03:48 PM |