you will need to run a new earth lead from main body to tailgate itself [by passing hinges]. they rely on hinges for earth connection,but as vehicle gets older they rust and cause problems like you have.
k, September 2010
Dirty contacts on the tailgate bottom edge or poor earthing through the tailgate hinges