Otherwise, that teacher should find a different line of work.
No teacher should ever, ever force a student to say or to stand for the Pledge. Case law goes way, way back on reciting the Pledge, I believe from 1943 when some Jehovah's Witnesses won their case in front of the USSC. Standing for the Pledge would be a similar violation.
Teachers have NO business inserting their political beliefs in the classroom.
If I had been that teacher's administrator, that teacher would have been fired on the spot.