The exact same thing happened to me!!! I was listening to music and then when I took my headphones out, the end of my headphone was stuck in the jack. At the beginning my volume wasn't working because my computer thought I had headphones in. Now, my volume won't work AT ALL! I went to the apple store and they said that they would have to replace the entire logic board for it to work. Last summer, they also replaced my logic board and I find this very ridiculous. NOT TO MENTION THE FACT THAT IT WAS THEIR HEADPHONES THAT GOT STUCK IN MY HEADPHONE JACK!!!!! It costs $800 to get a new logic board so does anyone know how to fix it?
I have had this problem for going on 2 years now, but I am always able to fix it. The problem can usually be alleviated simply by unplugging anything in the headphone jack and shutting down and restarting the computer. It seems like in everyone's case here it seems to be a sensor issue, so jiggling the plug or finding something like a matchstick to reset it usually works, too, though I use that as a last option due to a fear of long term damage. The six step process listed earlier has also worked for me.