I found out the problem with mine. I went to a repair store and they told me that nothing was wrong with the USB port or the battery. They said the problem was with an IC that affects the way the phone charges. It got burnt out. They said I'd have to replace the affected board. It seems that it's time for new smartphones guys.