I'm going to guess that your problem arises from two issues. Please note that this is a complete guess because I don't see enough of your code to say anything more. I could very well be completely wrong.
- $srch_host isn't being set or is mispelled. You probably need to add use strict; at the top of your script. That should catch a lot of spelling errors.
- $LookFor is being concatenated to. That looks really weird, seeing as you're specifying the complete match with ^ and $. I would assign to $LookFor and go from there.
Of course, if you were to post a larger snippet, we would be able to see the issue(s) more clearly.
------
We are the carpenters and bricklayers of the Information Age.
The idea is a little like C++ templates, except not quite so brain-meltingly complicated. -- TheDamian, Exegesis 6
Please remember that I'm crufty and crochety. All opinions are purely mine and all code is untested, unless otherwise specified.