Please describe the problem in detail and clearly so that you can get targeted help.
If you can explain the [specific] situation of the text to be processed (for example: is it all at the beginning of the line? Or is it generated from scratch? etc.), things may be much simpler.
In order to help you deal with fixed abcd#2#, I now assume that the operation method you need to perform is as follows:
And assume that abcd#2# appears anywhere in the text;
And assuming you want to handle all:
▼Select one of the abcd#2
# Please follow the steps below to solve the puzzle: 1. Right-click the menu bar to pop up the right-click menu. 2. In the right-click menu, select "Select All Occurrences". 3. You can also use the default shortcut key CTRL Shift A to perform this operation. With the above steps, you will be able to select all matches, helping you solve the puzzle faster. Good luck!
Now, we can see that abcd#2# in the text has been selected, because EmEditor supports multi-select block/multi-point simultaneous editing. This function can help us perform editing operations more conveniently.
▼Now use the [Unselect Block] command once (default shortcut key: Esc)
▲Note: Only press once
▲Click only once: Cancel all selected blocks, but still maintain multi-point editing status
▲Press again: Exit multi-point editing state
▼Now (as shown in the picture) all editing points are located behind each abcd#2
# (This step is actually not necessary, but to see it more clearly)
▼Now use the left arrow key (←) to move the editing point to the location you want (i.e., between each abcd and #2#, as shown in the picture)
▼Right-click menu >>Advanced >>Number (default shortcut key: ALT N)
(as shown in the picture) In the dialog box:
Select [Decimal]
First line: 1 (can add leading 0, such as 001)
Increment: 1
The result is as shown:
The above method is rather special, but easier to operate.
If the situation is more complicated, please ask for explanation and I will suggest other ways.
Give you a simple processing suggestion, the steps are as follows:
1. Classify all text files, for example: text type a is placed in the directory text/a/, text type b is placed in the directory text/b/, and so on. This sorting process can be directly implemented using the search function of Windows.
2. Download an editor, such as ultraedit, editplus, etc. This editor has a directory file search and replacement function, and of course it can also regularize.
3. After the download is completed, use the folder replacement function to uniformly replace the files in each category folder.
Tips, be sure to back up the source files. If you use it for the first time, you will definitely make mistakes. If you don’t back it up, I won’t be able to see you if you cry.
Let me show you a picture (an example of UE)
1. Click function key-Search-》Replace in file
2. Follow the example in the picture, fill in the content you want to replace, select the file directory where the file you want to replace is located, and click Replace All
The above is the detailed content of emeditor batch replace text. For more information, please follow other related articles on the PHP Chinese website!