My MDI cable does this exact thing. But I know for a fact that the cable itself, is the culprit. I'm getting my car serviced on Monday, and I'm sure they'll just swap it.
If it is your MDI, do the following:
Get it plugged in, nice and tight. Then, carefully jiggle the cable around at the point where the connector housing is. DON'T jiggle the plugs, only a small section of the cable. If you hear the sound cutting in and out, or otherwise effected by the movement; then it's the cable. If not, try other devices to see if it's repeatable, which could mean it's the dock input.
I'd bet anything that it's the cable though. These MDI cables are really crappy, and the placement of the "dock" almost seems designed to make you keep replacing the cable. I'd open mine up and try to fix it myself, but the 30 pin iPod plug would be a HUGE pain in the ass to solder. My times worth more than 36 bucks.