I've had the same problem for a long time now. Replaced chargers, even replaced the battery, I did one simple thing and it seems to have fixed the problem for me..
I cleaned the cable port.
It never even occurred to me, but I looked in it and saw that it was quite filthy. Just get a needle or...