VISALIA, Calif. (AP) — A California high school teacher pleaded not guilty to several charges of child cruelty and battery after she allegedly forced a haircut on one of her students, authorities said.

Tulare County District Attorney Tim Ward said in a news release Friday that Margaret Gieszinger, 52, faces up to 3 years and 6 months in jail if convicted of all six counts.

Gieszinger pleaded not guilty to the charges and was released, said Stuart F. Anderson, a spokesman for the district attorney's office.

The science and chemistry teacher was arrested Wednesday after video posted to social media showed a student at University Preparatory High School in Visalia sitting in a chair as she cuts his hair.

In a video obtained by KFSN-TV, she is heard belting the "Star Spangled Banner" while cutting the boy's hair and tossing chunks behind her. After cutting the boy's hair, Gieszinger grabs at a girl's long hair before the students make a run for it out of the classroom, the video shows.

Anderson did not know the name of Gieszinger's attorney and it was not listed in electronic court records. The county public defender's office did not return an email from The Associated Press seeking comment.

She is due back in court later this month.

Copyright 2018 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.