(a) A municipality may adopt, amend, repeal, and enforce ordinances or rules for any purposes authorized by law.
(b) An ordinance or rule adopted or amended by a municipality under this chapter or under its municipal charter authority shall be designated as either criminal or civil, but not both.