
In Yahoo Pipes, the String Replace Module allows you to find and replace text strings. You can specify whether you want the first, last or every occurrence to be searched and replaced.
For example, if you have a user input set up, and the user types in “Dolphins”, “Patriots”, “Giants” – you could use the String Replace Module to automatically replace those search terms with “Raiders”, “Colts”, “Cowboys”. This could prevent the user from searching for something you don’t want them to.
In this example, we’re going to change “volkswagon” to the proper spelling “Volkswagen”. We’ll use the Text Input Module to simulate a user search in Yahoo Pipes.
Lets make the Name “carsearch”, the Prompt “Search For A Car”, the Position “1”, Default “volkswagon” and Debug can stay blank.

Now to fix the spelling mistake (Volkswagen is spelt with an “e” not an “o”) we can use the String Replace Module to automatically fix it.
The String Replace Module allows us to match: first, last or every match.
Let’s wire the Text Input Module into the String Replace Module and match “every” “volkswagon” with “Volkswagen”.

Before the String Replace Module:

After the String Replace Module:


Recent Comments