If you use Mac OS X, you're comfortable mucking around with really dirty scripts, and you want to change your smtp server for every time you change location, try autosmtp what I just wrote in a fit of utter geekness. Filthy, dirty script.

(Can I just point out that I would never be able to do anything like this on Windows or Mac OS Classic. But because Mac OS X and the unix underpinnings are so tightly bolted together, I can use Perl (which is easy, and I know from making websites) to bolt together all the bits I only slightly know, and still make my day-to-day gui existence easier. This is what an OS should be like.)