MADISON, Wis. — A Wisconsin judge issued a temporary restraining order Friday blocking the state’s new and contentious collective bargaining law from taking effect, a measure that drew tens of thousands of protesters to the state Capitol and sent some Democrats fleeing to Illinois in an attempt to block a vote on it.