Typical trailer wiring and colors
GROUND to trailer frame---------------WHITE
Electric Brake Power------------------BLUE
Truck Battery Power-------------------RED or BLACK
Back up lights------------------------PURPLE
Right...Stop/Turn---------------------GREEN
Left....Stop/Turn---------------------YELLOW
Rear/Side Markers....License----------BROWN
Disconnect the wiring
Use meter to ID circuits from truck (pigtail plugged in)
Then twist wires together and CHECK that they run correct lights before permanently connecting
Make sure you ID and connect trailer ground FIRST