ClickHelp User Manual

Global Find and Replace

Thanks to the Global Find and Replace feature, it is now possible to find and replace text, topic links, and file links. The following entities can be searched in a single place across your entire portal: topics, styles, scripts, ToDo items, Index keywords, TOC nodes, and Unresolved/Resolved/Deleted review comments. So, you can easily clean up your content and styles, find and replace all occurrences of an external URL, and much more! There is no need to do it manually.

Here is how you can get to it:

  • Open Projects page.
  • Click Tools, then click Global Find and Replace.
    The Global Find and Replace button in ClickHelp main menu
  • The Global Find and Replace page will open. It looks like this:
    The Global Find and Replace page

When searching and replacing text, this function handles the following locations:

  • Topic title,
  • Topic HTML source,
  • Styles,
  • Scripts,
  • ToDo items,
  • Index keywords,
  • TOC nodes,
  • Unresolved/Resolved/Deleted review comments.

Let's take a look at a use case: we have a project about robots creation, and we want to change the word "parts" to "components". Here are the steps to do this:

  1. Open Global Find and Replace.
  2. Select the search mode. We'll use the Text mode.
    The Text search mode in the Global Find and Replace window 
  3. Fill in the search string.
    Fill in the Search field in the Global Find and Replace window
  4. Check the filter boxes to specify the search areas.
    Check the filter boxes to specify the search areas
  5. Click Find All to see the results.
    Click the Find all button to see the results
  6. In the search results list, you can select the topics in the content of which you want to change the word.
  7. Fill in the Replace with field.
    Fill in the Replace with field
  8. Click Replace Selected or Replace All depending on your goal. We will click Replace Selected to change the word in 4 selected topics.
  9. Then you will see the result.
    The Resulting page of the Global Find and Replace

Global Find and Replace Use Cases

Scenario #1 — Find and Replace Text

This is the simplest use case, and it is straightforward — just follow the steps described above in our example.

Scenario #2 — Find and Replace Links to Topics, External Links, and File Links

For example, we need to find all topics where we added a specific YouTube link. To do this:

  1. Copy a link to that video and paste it to the search string.
  2. Check the filter boxes as it's shown in the screenshot.
  3. Then click Find All to see the results.
Use the Global Find and Replace option to find the link to the video

Scenario #3 — Find and/or Replace Text in ToDo Items, Review Comments, Index Keywords, TOC Node Titles

Note
You can't replace text in ToDo items and Review Comments.

The steps are the following:

  • Fill in the search string with the text you are looking for.
  • Check the relevant search filter boxes.
    Check the Index Keywords search filter box to find the necessary index keywords
  • Click Find All.
  • Fill in the Replace with field. 
  • Click Replace Selected or Replace All depending on your needs.

Scenario #4 — Find and Replace Variables

In this case, you should use regular expressions. To learn more, refer to this topic:  Regular Expressions. 

Scenario #5 — Clean Up Topics After Importing

In this case, you should use regular expressions. To learn more, refer to this topic: Regular Expressions

Scenario #6 — Find and/or Replace a Variable, Snippet, Conditional Block 

For example, to find out in what topics a snippet is used, do the following:

  • Open your topic and click Edit.
  • Click a snippet and then click the Global Find and Replace icon.
    Click the Global Find and Replace icon to find where the snippet is used
  • Then you'll see the results.
    The results of finding a snippet
  • You can apply custom search filters.
    Apply custom search filters in the Global Find and Replace window
  • Then fill in the Replace with field — you can just click the field and ClickHelp will provide you with the recently viewed topics, so you can just click one of them.
    The list of the recently viewed topic in the Global Find and Replace window
  •  Otherwise, you may insert the link of a topic.
    Insert a link to the topic in the Replace field
  • Then select a topic where you want to replace the link and click Replace Selected or, if it's needed, click Replace All.
    Choose the topics and click the Replace selected button
  • Then you'll see the result:
    The resulting page of the Global Find and Replace

Scenario #7 — Find and Replace a Video Link

For example, you embed a video from YouTube in different topics but you need to replace it with a new one. Follow the steps:

  • Open a topic with the video.
  • Click the video the link of which you want to replace.
    Click the Global Find and Replace icon to find the link to the video
  • Global Find and Replace will open.
  • On YouTube, find the new video you'd like to use.
  • Click Share, then click Embed.
  • Copy the link URL as it's shown in the screenshot.
    Copy the link to the video to find and replace it
  • Paste the URL to the Replace with string.
    Paste the copied URL to the Replace with field
  • Then select a topic where you want to replace the link and click Replace Selected (or, if it's needed, click Replace All).
    Select a topic where you want to replace the link and click the Replace Selected button
  • Then you'll see the result.
    The resulting page in the Global Fins and Replace window

To find more use cases, refer to this topic: Regular Expressions.