Advanced Text Replacement Tool
Replacement Rules
Replacement Operations
Mode Settings
Clear Operations
🔍 Regular Expression Examples:
\d+ matches one or more digits |
[A-Za-z]+ matches English words |
^.{3,}$ matches lines with at least 3 characters |
apple|orange matches "apple" or "orange" (use | to separate multiple targets)
💡 Tool Detailed Instructions
This tool provides powerful text replacement functionality, supporting both plain text and regular expression replacement. It's ideal for batch text processing, data cleaning, and format standardization.
🔁 Replacement Functions:
- Perform Replace: Execute replacement operations on input text according to set rules
- Global Replace: Replace all matching content in the text
- Line-by-Line Replace: Process text line by line, applying replacement rules to each line individually
- Test Replace: Preview replacement effects without actually modifying text
- Email Example: Load example rules for email address processing
- Phone Example: Load example rules for phone number processing
⚙️ Mode Settings:
- Case Sensitive: Distinguish between uppercase and lowercase letters when matching
- Whole Word Match: Only match complete words
- Regex Mode: Use regular expressions for pattern matching
- Multi-line Mode: In multi-line text, ^ and $ match the start and end of each line
📝 Replacement Rules:
- Find: Enter text or regular expression patterns to find
- Replace with: Enter text to replace with, can use $1, $2 etc. to reference regex groups
- Multiple Find Targets: Use vertical bar | to separate multiple find contents, e.g. "apple|orange|banana"
- Regular Expressions: When regex mode is enabled, you can use special characters like \d (digits), \w (word characters), . (any character), etc.
🧹 Clear Operations:
- Clear Spaces: Remove all spaces (including spaces, tabs, etc.) from text
- Clear Line Breaks: Remove all line breaks, merging multi-line text into a single line
- Clear Symbols: Remove all punctuation and special characters, leaving only letters, numbers, and spaces
- Clear Numbers: Remove all numeric characters from text
- Clear Extra Spaces: Merge multiple consecutive spaces into a single space, and remove leading/trailing spaces
- Clear All: Clear all content in input and output text boxes
📋 Text Operations:
- Copy Input: Copy text from input box to clipboard
- Cut Input: Cut text from input box to clipboard (copy and clear input box)
- Clear Input: Clear all content in input box
- Copy Output: Copy text from output box to clipboard
- Swap Text: Swap content between input and output boxes
💎 Usage Tips:
- Use | separator to replace multiple different texts at once, e.g. "cat|dog|bird"
- In regular expressions, use parentheses () to create groups, and use $1, $2 in replacement text to reference them
- Combine "Clear Extra Spaces" and "Line-by-Line Replace" for efficient data cleaning
- Use "Test Replace" to preview effects before performing actual replacement to avoid mistakes