Replace Pioneer Home
All Examples
Free Download
all
Advanced search and replace
Replace text in multiple files
Regular expression replace
Batch file rename
Batch download
Text file parser
Text file splitter
Html text generator
Search replace binary
Random word generator
Count and statistics
Character encoding
Bin Hex Oct Dec converter
Text generator
Text sort
Text merge
Text data calculation
RSS: Replace Pioneer Examples
432.Regular expression replace -- How to add html tag of "strong" for each pair of "bold" tags?
User:
editor -- 2010-02-26
<< 431
433 >>
Hits:
644
Type:
Regular expression replace
Search all
Regular expression replace
examples
Description:
How to add html tag of "strong" for each pair of "bold" tags?
Input Sample:
<html>
...
<b>replace</b>
...
<b>search</b>
<b>regular expression</b>
...
Output Sample:
<html>
...
<strong><b>replace</b></strong>
...
<strong><b>search</b></strong>
<strong><b>regular expression</b></strong>
...
Answer:
Hint: You need to
Download and install "Replace Pioneer"
on windows platform to finish following steps.
1. ctrl-o open html file
2. ctrl-h open replace window
* in 'search for pattern', enter:
.*?
* in 'Replace with pattern', enter:
$match
3. click 'Replace', done!
Download Script:
scripts/432.rst.zip
Screenshot 1: Replace_Window
Similar Examples:
How to enclose all the odd number of lines with a pair of tags?
(51%)
How to batch rename html files to the content that between a pair of h2 tags?
(51%)
How to add first line to the start of each line?
(49%)
How to add a space at the specific location of each line?
(49%)
How to add a number and remove "new line" for each segment separated by "@"?
(49%)
How to add a <BR> at the end of each line?
(49%)
How to add a semicolon at the end of each line?
(48%)
How to add a single space after each character in a text file?
(47%)
Check Demo of
Regular expression replace
Keywords:
bold
strong
tags
html tag
tag
add html
regular expression
expression
old
rst
replace bold tag
replace replace replace html tags
tag html
replace html
add 1
search pattern
search replace
to replace