Search and replace tool

The search and replace tool allows you to search for a single word or a phrase and replace it with a different text value. You can also select which part of the system you would like to search in and filter by asset type.

The search and replace tool lets you replace a word or phrase in text fields and anywhere where the word appears in an editable location. Put another way, replacing text matches includes, among other things, attribute and metadata fields displayed in matching search results.

Prerequisites and caveats

For this tool to work, you must turn on indexing in the search manager. Read Setting up the search manager for more information about configuring search indexing.

If a matched asset has workflow applied to it, the tool will only replace a word or phrase on that asset if it meets either of these requirements:

  • The asset’s status is in Safe edit.

  • The user making the changes is an approver of all steps of the workflow.

Search terms

This section allows you to specify the details of the terms that you want to search and replace.

Search string

Enter one or more words for which you want to search.

Replace string

Enter the text that will replace the searched string.

Match case of target string

Check this box only to return an asset if its contents match the case of the search term you enter. If you leave this box unchecked, the tool will return an asset match if its content matches the search term, whether it is the same case.

Search restrictions

This section allows you to specify the details of the assets to include in the search.

Asset types

Select one or more asset types to include in the search. To include all asset types in the search, leave this field blank.

Asset status

Select one or more asset statuses to include in the search. You must select at least one status from the list for the search to work.

Search location

This section allows you to specify which part of the system to search in.

You need to specify either the root node or select System-wide to make the search work.
Root node

Select one or more root nodes under which to narrow the search.

System-wide

Check this box to search the entire Matrix system.

Search and replace example

To perform a search and replace, follow these steps:

  1. Enter the term or phrase you want to search for in the Search string field.

  2. Enter the term or phrase that will replace the searched term in the Replace string field.

  3. Select the asset type to search in the Asset types to search field. If you want to search within all asset types, leave this field blank.

  4. Select the type of status the asset must be to be included in the search. You need to select at least one status from the list for the search and replace to work.

  5. Select either a root node to search in (for example, your site) or search System-wide. You need to select at least one option for the search and replace to work.

  6. Click Save. A HIPO job will appear on the Editing screen.

    5 0 0 global search and replace hipo progress

    If an asset has been found containing the search term, it will be listed in the HIPO job. For example, in the previous example, the newsletter and the news assets contain the searched term.

  7. Expand the search result to find where in the asset the term has been found. Matrix will highlight where it found the term.

    5 0 0 highlighted search terms
  8. Select which occurrences you want to replace by clicking on the checkbox. If you want to replace all occurrences, click one of the Select all hyperlinks.

  9. Once you have selected which occurrences to replace, click the Next button. The HIPO job will continue, and the search and replace will happen for the assets you selected on the previous screen.

  10. Click the Cancel button to end the search and replace.

© 2015-2020 Squiz Pty Ltd