I won't get in the details about how a relay works but the Switch in the car simply acts as a contact to "tell" the relay to let the current through. So I think what happened with your wiring is that you were getting "Positive" current twice to your ballast.
My picture is how I'd wire it up, missing the Fuse but yeah, you should get the basic idea.