Iphone 4s no sound or control of sound?

So today my iphone 4s stopped playing sound through the earphones and without them i couldn't adjust the volume in no way but i was Still getting sound from incoming or out going calls and my alarm. I went back and as i was placing my phone on charge i noticed the soundbar and sound was working again then i noticed something else the sound/soundbar only worked with my charger inserted in to the bottom. I tried the apple site and forums but as it being apple was no help at all. Any ideas on how to repair or what to do?

Added (1). I'm on contract.

Broken. Sell it

Take the phone back to the store where it was brought and ask them to repair it.
the phone might this be under warranty.

Try making sure the little bar on the side is on so it makes sound (It will pop up on the screen which action you done) It that still doesn't wort try Settings > Sound then turn it up. If that doesn't work bring it back to your carrier.

  • Things you wish you could control with your iPhone? I'm taking a computer course program thing over the summer so that I can have an extra credit in 12th grade. We have to think of things that we should be able to control using our phones. Things like lights and stuff but I'm completely stuck. Any help?
  • Parental control on iPod Touch / iPhone? If I'm using someone else's Wi-Fi, can they restrict what websites I visit from their computer? Even if they've never touched my iPod or iPhone? Or do they have to physically access my iPod? Also, can they check my internet history from their computer? If I delete my history can they still see it? I don't want to sound sketchy haha, I'm allowed to use their Wi-Fi but I just don't want them to see what sites I visit.
  • My iPhone (3GS) randomly started playing a song and turning voice control on today? Today, when I was in second period at school, my iPhone randomly started playing a song from my library. In third period, while doing an assessment, voice control turned on. At lunch, I turned my phone off and took it out of my back and put it in my inside blazer pocket. It might be a new bag I started using today that caused the problem. I really want to know how to stop this so I can stop worrying. (;
  • Light control apps for iphone? I was wondering if there were any iphone apps available that can control your lights, tv etc and to use them you DON't need to buy some sort off device to go with it. Maybe the app could use the model numbers of things or something:/