Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 10-29-2024, 05:44 PM   #1
DarkRookie2
Member
DarkRookie2 began at the beginning.
 
Posts: 17
Karma: 10
Join Date: Oct 2019
Device: None
Issue with RegEx

I am trying to use RegEx to replace some things.

I have a lot of Page # and Page ## in the book.

I have used https://regexr.com/ and https://regex101.com/ to make figure out what I needed.

It turns out to be
Code:
(Page \d+)
But when I paste it into Sigil, it doesn't find any. I have made sure I have All HTML Files selected. And I did it on Current File on a few different HTMLs but it isn't picking up any of them.

Not sure what I am doing wrong.
DarkRookie2 is offline   Reply With Quote
Old 10-29-2024, 05:45 PM   #2
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,437
Karma: 5702578
Join Date: Nov 2009
Device: many
Have you set Sigil's FindReplace to Regex Mode not normal mode? See the menu pulldown in the lower left of the Find and Replace screen.

Could there be a tag you forgot to include between the Page and number.

Last edited by KevinH; 10-29-2024 at 06:17 PM.
KevinH is offline   Reply With Quote
Old 10-29-2024, 05:49 PM   #3
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,679
Karma: 23983815
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by DarkRookie2 View Post
Not sure what I am doing wrong.
There might be several spaces between Page and the number. Try:

Code:
(Page\s+\d+)
Doitsu is offline   Reply With Quote
Old 10-29-2024, 08:17 PM   #4
DarkRookie2
Member
DarkRookie2 began at the beginning.
 
Posts: 17
Karma: 10
Join Date: Oct 2019
Device: None
Quote:
Originally Posted by Doitsu View Post
There might be several spaces between Page and the number. Try:

Code:
(Page\s+\d+)
This did it. Weird. I copied and pasted a few from code view into the testers to check with.
DarkRookie2 is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Regex Rename Issue KarlG Sigil 20 10-07-2024 06:05 AM
pdf regex question - regex that wraps to a new line flyash Conversion 1 09-05-2021 09:00 AM
Predefined regex for Regex-function sherman Editor 3 01-19-2020 05:32 AM
regex - issue with spaces? cybmole Editor 43 12-31-2013 12:49 PM
regex Issue when Importing river Calibre 3 06-16-2009 11:03 AM


All times are GMT -4. The time now is 12:17 AM.


MobileRead.com is a privately owned, operated and funded community.