What you should do for your own code is use Variables and not embed hostnames or IPs in your code. This will allow you to easily modify this code in the future and share it with others by simply removing the variable definitions.

Posting it here would be appropriate. If you wish, send it to me as a PM and I'll format it and post it in the script vault, where there are several other "ready to use" scripts and script fragments.

Glenn
_________________________
Actually I am a Rocket Scientist! \:D