If the title is always the same , you can
find : (Delphi [^(]+)\([^)]+\)
replace : \1
if you want to get rid of an optional space before the bracket, put :
find : (Delphi [^(]+)\s?\([^)]+\)
replace : \1
with "dot all" unchecked
If the title is always different (e.g. chapter title) you have to have a significative part, e.g. <h1> or <h1 class="myclass"> in :
<h1>Something (something else)</h1>
find: (<h1[^(]+)?\s\([^)]+\)(</h1>)
replace: \1\2
(deleting the optional space)
If you have trailing chars, like in
<h1>Something (something else), part 3</h1>
then :
find: (<h1[^(]+)?\s\([^)]+\)(.*?)(</h1>)
replace \1\2\3
Last edited by lomkiri; 05-04-2025 at 11:27 AM.
Reason: regex with <h1> modified
|