in reply to Detecting dial-up connections

<Previously unmentioned> There is some registry value which is true if the computer is currently connected to the Internet. I would actually recommend searching around a few VB sites (in the 'Tips and Tricks' section). Once you find out the registry ID, key or whatever it's called, there is some module in the Win32:: hierarchy that lets you look at its value.

So, it could be as simple as:

if ($whatever_key) { print "I'm online!\n"; }
</Previously unmentioned>