My Iphone does not charge at all?

My iphone 4 on ios 5.0.1 has been having problems charging. Every time I plug it in with official apple cords, I get a message saying accessory not supported. I have tried everything, from cleaning the dock to buying a new cord, and I'm pretty sure it has no water damage.

Then go to school, work hard, go to medical school, become a doctor, and buy a new one

Try rebooting it. Hold sleep and home button until the phone shuts off, keep holding until the Apple logo reappears then let go. Try charging again.

System has gone wrong?