Red and black are power lines, white and green lines are used to transmit data
The four lines in the mobile phone charger are: red, white, green and black. Two of the lines are data lines, and two of them are power lines including ground.
Red line: Positive power supply (marked on the wiring: +5V or VCC).
White line: Negative voltage data line (identified as: Data- or USB Port -).
Green line: Positive voltage data line (identified as: Data+ or USB Port +).
Black line: Ground (identified as: GND).