Why does my iPhone / electronics still work even when dropped in water?
First of all, as Ignacio Vazquez-Abrams commented, not all water is the same.  At the extreme ends, salt water is 100,000 times more conductive than distilled water (so don't drop your iPhone in the ocean!).  Tap water is in-between at 1000 to 10,000 times more conductive than distilled, depending on the amount of total dissolved solids (TDS).

But I assume you are talking about the same or nearly the same water in your question re an iPhone and other electronics.

The biggest factor in determining the potential for water damage is of course the amount of water that can get int the case.  iPhones and iPods are nearly hermetically sealed.  There are very few places that water can get in.  The earphone jack looks like a possibility, but actually it is just a little tunnel into a solid block of plastic (the jack) that will not let any moisture in.

So compare that with other electronics you may have in mind, and I bet they are more susceptible to letting water get inside.

So the two issues are, the conductivity of the water, and the amount of exposure.

If you have a piece of electronics that has been in water, do not turn it on.  If it is already on, shut it off.  If it has a removable battery, remove it.  I know in the case of the iPhone this takes a special tool, which consumers don't have access to (although you can buy them off Amazon, e.g. here).  I guess you could try taking it to any Apple Store and have them remove the case if you really want to.  There are also blogs on the web that give instructions on removing a iPhone battery.

One often-suggested method way of drying out a piece of electronics is to put it in a bag of uncooked rice and wait 48 hours before turning on the device.  Another is to use a BHEESTIE bag, which is like the rice but works seven times faster.  But of course you already have to have one.

However this article says using rice is a bad thing to do.  Go figure.  Seems a lot of people are using the rice trick successfully.

In any case, do not use a hair dryer, as the air will just drive any water further inside the case.

I've also seen people talk about putting a water-damaged device into an oven overnight at 130-160 deg F.