Notwithstanding any law to the contrary, whenever a person violating any of the provisions of this chapter or chapter 9 of this title or parts 1-5 of chapter 10 of this title is required, at the discretion of the court, to attend a driver education course approved by the department of safety, in addition to, or in lieu of any portion of, any other penalty imposed, the court has the discretion to allow the violator to attend a driver education course in the person’s county of residence, instead of attending a course in the county where the citation was issued. The driver education course shall be approved by the department of safety and operated and conducted in accordance with the requirements of § 55-10-301.