iPhone pauses or plays songs when the headphone plug moves My iPhone 3GS has decided to pause music playing when the headphone plug happens to move a bit or to start playing music without warning for the same reason. Sometimes it also skips to the next song or podcast. It's very annoying.

Is there some way to tell my iPhone not to do that?

The headphones are original Apple headphones for the iPhone. I bought two pairs and it happens with both pairs but only with that iPhone. I have a second iPhone 3GS which doesn't appear to react like that.
It happens because a quick jog of the plug causes a short interruption in line level.  It's the same with headphones -- Apple or otherwise -- that include a play/pause button (usually place on the cable itself, where it splits to go to each ear).  That button functions in exactly the same way, by momentarily interrupting line-level on the phone's cables.  iTunes starts playing because it assumes the interruption from plug movement (or a dirty plug) is a play/pause signal.  As a simple demonstration, start iTunes playing something and wiggle the phones jack, same conditions as make iTunes launch and play, only if it's already playing this will make it pause.