If you have trouble, like me, understanding and using the above script, you may want to look at the below for a simple example:
For more information, see the wiki Searching the Forum for Answers section.