07-05-2015, 01:49 AM | #1 | |
Addict
Posts: 378
Karma: 3102
Join Date: Dec 2010
Location: EU
Device: Kobo Aura ONE, Kobo Libra H20
|
Search & Replace Help
I have the following strings in Conversion -> Common options -> Search & Replace
Quote:
Unfortunately, it doesn't seem to work. Maybe the regex is wrong. It works fine when I do it with Sigil. Thanks! |
|
07-05-2015, 03:53 AM | #2 |
Addict
Posts: 378
Karma: 3102
Join Date: Dec 2010
Location: EU
Device: Kobo Aura ONE, Kobo Libra H20
|
Looks like changing
Code:
<a class="([^"]*?)" id="([^"]*?)"></a> Code:
<a class="(.*?)" id="(.*?)"></a> But why is the former regex working in Sigil and in the Quality Check PI and not in Calibre conversion? |
Advert | |
|
07-05-2015, 04:01 AM | #3 |
Ex-Helpdesk Junkie
Posts: 19,422
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Why not simplify on one regex:
Code:
<a( [^>]+)?></a> |
07-05-2015, 04:11 AM | #4 |
Addict
Posts: 378
Karma: 3102
Join Date: Dec 2010
Location: EU
Device: Kobo Aura ONE, Kobo Libra H20
|
Many thanks, eschwartz
That's great. And this one works in calibre conversion, Sigil and the Quality Check PI. |
07-05-2015, 04:21 AM | #5 |
Ex-Helpdesk Junkie
Posts: 19,422
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Awesome!
|
Advert | |
|
08-02-2015, 02:56 AM | #6 |
Addict
Posts: 378
Karma: 3102
Join Date: Dec 2010
Location: EU
Device: Kobo Aura ONE, Kobo Libra H20
|
I may be doing something wrong after all.
With this regex in Search and Replace... Code:
<a( [^>]+)?></a> Code:
<a id="page34"></a> Last edited by paulfiera; 08-02-2015 at 07:49 AM. |
08-05-2015, 10:24 AM | #7 |
Ex-Helpdesk Junkie
Posts: 19,422
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Like I said, no idea why any of these should fail during conversion.
|
08-06-2015, 03:52 AM | #8 |
Addict
Posts: 378
Karma: 3102
Join Date: Dec 2010
Location: EU
Device: Kobo Aura ONE, Kobo Libra H20
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Search & Replace | Scott Nielsen | Sigil | 4 | 10-29-2013 12:10 PM |
Search & Replace Problem | mapline | Calibre | 3 | 08-04-2012 07:18 PM |
Help with a search & replace | mmholt | Library Management | 11 | 10-21-2011 06:49 PM |
Search & Replace :help: | krussell | Calibre | 3 | 08-02-2011 04:45 PM |
Search & Replace | Pat Nickholds | Sigil | 2 | 10-21-2010 11:18 PM |