Bad cables cause many "phone won't charge" complaints.
1. Look for damage at both ends: fraying, bent plugs or burnt marks.
2. Charge a phone that you know works with the cable and see if the charging icon stays steady.
3. Wiggle the cable near each plug. If charging stops and starts, the cable is damaged.
4. With a USB meter, compare the current with a known good cable. Much lower current means a weak cable.
5. Test data by connecting to a computer. Some cables only charge.
Throw away damaged cables. Exposed wires can short and spark.