IF, and I say again IF a judge issues a gag order, violating it is simple contempt of court, and subject to the usual penalties for that.
A mayor, or a police chief does not have the legal authority to gag a private citizen.
I don’t even think a judge could pull that off.
Well, they don't have authority, not even legislative authority in Louisiana, to confiscate everyone's firearms either. But that didn't stop them from doing it in New Orleans.