22.214.171.124. Searching and replacing text
You can search for a specific text string within a selected content- or section-node. Optionally you can replace the occurences of the search string with another text string. Proceed as follows:
- Select a single content- or section-node and choose "Search and Replace" from the context menu. This will open following dialog:
Figure 2.3.27. Search and Replace dialog
- Enter the search string in the "Find what" field and click the "Find" button. The system will highlight all hit-positions in the preview area with yellow background color. The first hit-position is marked with a red background color.
- You can jump to the next hit-position by clicking the "Next" button.
- You can jump to the previous hit-position by clicking the "Previous" button.
- You can replace the search term at the current hit position with the text entered in the "Replace with" field, by clicking the "Replace" button.
- You can replace all occurences of the search term within the selected node, by clicking the "Replace all" button.
- Click the "Close" button to close the dialog.
Be aware that the search does not automatically transform special characters into character entity notation or vice versa. Therefore, if the HTML source of your content contains a character entity notation, e.g. "€" (the euro sign), but you entered in the "Find what" field the unencoded euro sign "€", then the search will not return any hits. You have to explicitely enter "€" in the "Find what" field to find the occurences of the entity notation "€" in the HTML source.
The "encode"/"decode" button can be used to automatically encode/decode special characters. If you have entered a search/replace string which contains unencoded special characters, then you can automatically encode these characters into the numeric entity notation by clicking the "encode" button above the "Find what"/"Replace with" input field. The other way around, if you have entered a search/replace string that contains a numeric or symbolic entity notation, then you can resolve this encoding by clicking the "decode" button. The encoding and decoding is done according to the character entity definitions which can be configured in the administration workspace (see Section 2.7.4, “Defining character entities”).
When the system searches for all occurences of the search string within the selected node (step 2), following options will be taken into account which can be set by the user:
If this checkbox is checked, then the search will be case-sensitive. Otherwise the search is case-insensitive.
Resolve structural inclusions
If a section-node is selected and the sub-tree of this section contains inclusion-nodes (section- or content-inclusions; see Section 126.96.36.199, “Inclusion-nodes”), then this checkbox controls whether the search will follow or skip the included nodes. If the checkbox is checked, then the search will find all occurences of the search string within any structurally included nodes (recursively).
Resolve inline inclusions
If a content-node contains inline-inclusions (see "Inline inclusions" in the tutorial), then this checkbox controls whether the search will follow or skip the included nodes. If this checkbox is checked, then the search will find all occurences of the search string within any included content.