Having an issue with a gadget? Maybe this will help.
Oh noes! I dropped my phone in the toilet/puddle/laundry, what do I do? As quickly as possible retrieve the phone and remove the battery. Shake off as much excess water as possible and pat dry with a towel. Place the phone into a zip-top baggie along with some dry white rice and seal the bag. The rice will draw the moisture out of the phone. Check occasionally, but for best results you will likely need to change the rice a few times - the whole process can take several days depending on how water-logged your phone is.
A note to Apple users: since your battery is unable to be removed just shut it down and skip the battery removal step. And a little FYI, your Apple device is equipped with several moisture sensors which can be pretty easily activated; doing so voids warranty, so keep it out of your sweaty pocket.