Lawsuit time. In spades.
West Virginia State Board of Ed v. Barnette (1943) found that Schools cannot force students to salute the flag, nor stand for the Pledge. The 1st Amendment protects the student’s rights to dissent.
Any action by a public school, or public school teacher to coerce students into standing or saying the pledge, including thanking those who did stand, can be seen as a violation of the student’s rights.