The charging port on my friend's phone was no longer gripping the cable connector, so it would fall out easily while charging.
I tried a cheap $4 part from eBay first, but wasn't able to finish because the part was a knockoff and not quite up to specs—the antenna cable was just slightly too short. I got the ifixit part next and it fit perfectly.
The phone had a power issue after the repair: it charged very slowly and the battery ran down much faster than normal. I opened the phone back up and cleaned all the electrical contacts I could find with rubbing alcohol. It worked fine after that. Always clean up after yourself!