|  01-06-2015, 01:32 PM | #1 | 
| Member  Posts: 11 Karma: 10 Join Date: Jul 2012 Device: Kindle 3G |  How to find using wildcards? 
			
			I converted a book from PDF to EPUB and using heuristics, the result is great. The only thing is that I have page numbers in middle of text. So I want to remove them all. In code, all of them look like this: Code: <p class="calibre1">25</p> I tried Code: <p class="calibre1">??</p> What should I type in to find every instance of code <p class="calibre1">..</p> with any two characters in place of ".."? | 
|   |   | 
|  01-06-2015, 01:53 PM | #2 | 
| Well trained by Cats            Posts: 31,249 Karma: 61360164 Join Date: Aug 2009 Location: The Central Coast of California Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A | Code: <p class="calibre1">\d+</p> \d+ matches only if there are 1 or more digits | 
|   |   | 
| Advert | |
|  | 
|  01-06-2015, 03:40 PM | #3 | 
| Ex-Helpdesk Junkie            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) | 
			
			Regular expressions are NOT wildcard globbing, they are much more powerful, look vaguely similar, and probably confuse a lot of people the first time they see them.   A basic intro to regular expressions might be in order.  http://www.regular-expressions.info Last edited by eschwartz; 01-06-2015 at 03:43 PM. | 
|   |   | 
|  01-08-2015, 10:45 PM | #4 | 
| Wizard            Posts: 1,090 Karma: 447222 Join Date: Jan 2009 Location: Valley Forge, PA, USA Device: Kindle Paperwhite | 
			
			I find the Calibre User Manual write up on regular expressions very readable (and a little entertaining also) http://manual.calibre-ebook.com/regexp.html | 
|   |   | 
|  01-08-2015, 11:32 PM | #5 | 
| Ex-Helpdesk Junkie            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) | 
			
			The calibre writeup is indeed readable, and entertaining as well. However, http://Regular-Expressions.info has a much more comprehensive writeup, as it is an exhaustive guide, and I find that to be more useful on a personal level. Additionally, my regex guide of choice has a pretty readable format as well, and I feel no need to switch mental tracks when offering regex suggestions (depending on the complexity of the matter) in order to *patronize* calibre's guide.  At the end of the day, either one can give you a basic rundown on the regex approach, which is what matters.   | 
|   |   | 
| Advert | |
|  | 
|  | 
| 
 | 
|  Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post | 
| Sigil Wildcards/Regex Find/Replace | Adman35 | Sigil | 7 | 08-16-2014 01:02 PM | 
| Regex/Grep and wildcards | John123 | Workshop | 2 | 04-12-2014 11:32 AM | 
| More fun with regex / wildcards | zelda_pinwheel | Sigil | 28 | 01-06-2013 09:57 AM | 
| using wildcards for conversion ? | Riiyachan | Calibre | 7 | 04-20-2010 10:16 PM | 
| wildcards in sigil | bobcdy | Sigil | 2 | 12-18-2009 10:19 PM |