Relays and Mosfets

Then you've not connected it correctly or your code is wrong. If you post the code and a simple connection diagram it may be possible to help but I'm not good at guessing what you might have done.

Steve