I am installing a new exhaust fan in my bathroom and along the joist I will be attaching it to, there is a black electrical wire that runs right along it. There is a bit of play in it, and I guess I can tack it upwards to move it out of the way, but was wondering what would be the best way to take care of this. I think the original installation had the fan either pinned up against the wire or had the wire sitting on top of the fan unit. The new fan unit is bigger, so I don't think it can sit on top of the box. Note: this wire is not the same wire that is providing electricity to the fan.
Wire staples work great for that. Just hammer it into the side of the joist.
In the UK house wiring uses Red for live, Black for neutral and Earth is bare copper (sometimes with a green or green/yellow sleeve). Take care, I've seen wire colours used in correctly - always verify. If you are not 100% sure get a qualified electrician, bad/ inncorrect house wiring can be lethal. For a plug (flex) Brown live (usually fused), blue neutral, green/yellow Earth. If you cut an old plug top off take out the fuse - this way is someone plugs it in to a socket they won't be exposed to live mains.
That's a situational judgment. If you put it above the fan, you have to be pretty certain that there's no chance that nails won't be coming down from the floor above. It's good to have the wires at least 1 and 1/2 inches away from ceilings and floors. You might want to give a gentle tug on the wire to see if you have enough play to anchor it safely mid-joist. It may look like crap, but you might want to add a piece of wire to lengthen it. You would want to put a junction box where each connection is made. It's not a good idea to bury junctions, so you want them accessible with cover plates.