have solved this problem with online help yesterday. It seems the script
should be used in conjunction with jsSiteSearch.js to work, and one needs to modify jsSiteSearch.js for the domain information. I have done so and it works fine.
That's just what I want. It's really simple indeed if you know it.