Set Infringement Words and Replacement Rules
NOT REQUIRED setting. Default is empty.
Call & Example Call
affx.set("word", "", append=True/False)
affx.set("word", "apple:banana, cat:dog", append=True)
Parameter Description
Rule: The word before ":" is the original word (infringement word), and the word after ":" is the replacement word. Separate different word pairs with ", ".
In the Example Call on this page, the infringement word "apple" will be replaced with "banana," and the infringement word "cat" will be replaced with "dog."
append:
Core Function
Define the infringement words and their replacement words you want to set. After generating web pages, the infringement words in the text will be automatically replaced.
Features
- Case insensitive.
- Automatically replaces according to the original word's capitalization. For example, if "apple:banana" is defined, then "apple" will be replaced with "banana"; "Apple" with "Banana"; "APPLE" with "BANANA".
- Replacement is not limited to text content; infringement words in image alt attributes will also be replaced.
- Replacement also occurs after regenerating web pages or replacing page images.
Example Output
Output
Replacement rules set successfully.
