Several months ago, my iphone 4s started having sound issues. It would play sounds when under the sound menu in settings, alarms, and it would ring when a call came through, but it would not play music, video sounds, text sounds, or sounds in any apps. I read some troubleshooting online and tried cleaning the dock connector and headphone jack with compressed air and backing-up and resetting the machine. None of these helped. Eventually, I gave up and a few days later it suddenly started working like normal.
A couple days ago, I noticed it didn't make the noise it usually does when I connected my phone to charge. Now, it is not playing sounds again. And, tonight as I was trying to sync and free up some space, it suddenly disconnected. The usb cord was still plugged in to both the phone and the computer, but the computer was telling me that there was no device connected. I've tried restarting the computer and the phone, unplugging and plugging back in the usb cable, but it will not recognize a device.