Does a computer recognise it if you plug it in via USB? If it doesn't (try it with at least 2 USB cables), the charging plug on the iPhone itself is probably broken. You'll need to take it to an Apple store or send it off to be fixed. It should be free if it's still under warranty, if not, unfortunately you'll have to pay for it to be fixed. I don't know how much it would be though, that's something you'd have to talk to Apple about.