There are many reasons for this everyday (yet absurdly annoying) phenomenon. Usually, though, it’s basically due to the loose wire which enable it to frequently be set by pushing the cable in the direction of the earpiece and, if needs be, fixing it into place with a little electrical tape, super glue, or other adhesive.
Now and again, if ever the earpieces have an inline volume wheel, that can be the reason. That one is slightly difficult to fix, but you could always try the ‘wire trick’ pointed out above and see if it works. If not, then open the volume wheel and re-solder the cables into place (be warned, this will invalidate most warranties, so if ever the ‘phones continue to be covered, just send ‘em back and find replacements).
Avoiding stuff like this happening in the future, it’s highly recommended to wrap your cables carefully and to avoid stressing your headphones. No, I don’t mean you should give Motorhead a break and simply play floaty, soothing New-Agey music on them, I mean that you shouldn’t have them within your back pocket whenever you sit down and you should detach them gently from your ears after use (this will sound evident, and you’d be astounded how some people simply rip ‘em out).
Another thing to take care for is the jack, if ever the cable is fraying/wearing around the jack, then that can also be a problem. Luckily, like so many things in life, a small amount of electrical strip can really come in useful, just ensure that the copper wiring is tightly bound and it should return to standard usage in no time.
Now and then, however, it is simply a sign that the headphones are knackered and no amount of skillful tinkering can repair them. Typically, in these cases, the challenge is inside. This particular variant on the trouble also attacks earpieces of any price range, be they Poundland specials or your year old Sennheiser Eargasm headset. I’m reminded of a Shakespeare quote from Hamlet, something about a king and the guts of an beggar, but I can’t be bothered to look the whole thing up right now. You get the point I’m attempting to make though, everything dies ultimately, no matter how much it cost you.