Replace Pioneer Home   All Examples   Free Download

 New request --free  RSS: Replace Pioneer Examples

895.Text file parser -- How to extract all text enclosed by H1 tag from multiple html files?

User: editor -- 2011-12-12          << 894  896 >>
Hits: 245
Type: Text file parser   
Search all Text file parser examples
Description:
How to extract all H1 text from multiple html files and write the output to a single file?
Input Sample:
<html>...
<h1>text 1 with h1 mark</h1>
...
<h1>text 2 with h1 mark</h1>
....
Output Sample:
text 1 with h1 mark
text 2 with h1 mark
Answer:
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps.
1. open "Tools->Batch Runner" window
2. drag multiple html files from windows file browser to "Batch Runner" window
3. click "Fast Replace" button
* click "Add" to add a new rule
* set "search" to: 
* set "replace" to: 
* click "ok"
4. check option of "reg exp", "ignore cases" and "extract"
5. click "start", and click "output to single file", all text that enclosed by <h1> and </h1> will be save to a single file.

Screenshot 1:  Fast_Replace_Window


Similar Examples:
How to extract all image links from multiple html files?  (72%)
How to extract text enclosed by "body" tag from many html files and join together? (70%)
How to extract all c++ comments from multiple cpp files? (69%)
How to extract all text that enclosed by html tag "strong"? (66%)
How to extract all specified links from a html file? (65%)
How to change all bold tag to bold-italic tag in multiple html files? (65%)
How to extract all image links from a html file? (65%)
How to extract unique ip addresses from multiple text/html files? (64%)

Check Demo of Text file parser
Keywords:
tag  ignore  case  single  text file parser  file parser  parse  pars  fast replace  fas  enclosed text search and replace  html tag  tag html  write to file  text file parser html  html file parser  search and replace text files parser  extract text from multiple files