| User: editor -- 2008-08-05 << 240 242 >> |
| Hits: 369 |
| Type: Advanced search and replace |
| Search all Advanced search and replace examples |
| Description: |
| How to add html tags for text file containing personal data information? |
| Input Sample: |
| Mike 28 male Tom 36 male Susan 25 femeal |
| Output Sample: |
| <person> <name>Mike</name> <age>28</age> <gender>male</gender> </person> <person> <name>Tom</name> <age>36</age> <gender>male</gender> </person> <person> <name>Susan</name> <age>25</age> <gender>femeal</gender> </person> |
| Answer: |
| Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps. |
| 1. ctrl-o open source text file 2. ctrl-h open 'Replace' dialog. * set "Replace Unit" to "Paragraph" * set "Replace with pattern" to: 3. Click "Replace", done! Note: for paragraph type, $match[1],$match[2]... means line1,line2... for line type, $match[1],$match[2]... means word1,word2... for word/chars type, $match[1],$match[2]... means character1,character2... Paragraph is automatically separated by blank lines, user can change the rule in settings page. |
| Download Script: scripts/241.rst.zip |
Screenshot 1: Replace_Window |
Similar Examples: |
| How to format all the data in the text file with 8.2 format? (55%) How to join multiple text/csv files in horizontal direction? (53%) How to convert IP addresses in text file into Hexidecimal format? (53%) How to split a text file according to first word in each line? (52%) How to removing all leading zeros in a text file containing many numbers? (52%) How to multiply all the numbers by 3 in a text file containing many coordinates? (52%) How to convert a text file to specified format? (51%) How to sort lines of text file by comparing the sum of column1, 2 and 3? (51%) |
Check Demo of Advanced search and replace |
| Keywords: |
| xml blank lines tags blank line html tag user paragraph blank tag automatically replace paragraph in xml file lines tags replace text in xml add blank lines replace replace replace html tags search and replace with blank lines add blank line replace blank lines |