I would suggest wiring it directly to the battery using a switch,fuse and a relay.It would be even better if you mounted a second battery to conserve the power for the electric motor that powers the cart.I don't know how you were trying to wire them in,I can tell you this much though with a headlight it doesn't matter what side is ground and what side is power.
Master ASE Certified.L1 Advanced Engine Performance Certified.Pa Emission Repair Technician.Just Answer Car Category Mentor.