Secondly, whether the girl was disreputably dressed, or merely unattractive, is irrelevant. It is not the teacher's place to make disparaging remarks. If her dress was so inappropriate she should not have been in the classroom, the child should have been sent, with an escort if necessary, to the appropriate disciplinary authority. Tossing the kid out the window is not the same thing as sending her to the Dean of Girls (that's what we had in my day 40 years ago) to be disciplined. If the child behaved inappropriately, by all means apply the proper, legal discipline.
You know, I DID think about what I would have though 40 years ago when I was in high school (and working hard for Goldwater, thank you), and I would have said the same thing. You may be in awe teachers, but I'm not now and I wasn't then. In those days I thought 3 out 4 did not belong in a classroom, whether because of stupidity, incompetence (not the same thing), mendacity or other unsuitable personality traits or personal habits (ever spend an hour a day in a closed classroom with a teacher who regarded bathing and soap as personal enemies?). My view has changed little subsequently, although I would say in my own children's experience perhaps as many 2 out of 5 were competent, if you include some amazing vocal music teachers.
Actually as long as you are in a public place, anyone may freely take your picture. What they do with that picture is limited.
Commercial sale/publication of that photo could possibly require a release from persons in that photo but it is not absolutely necessary if the person was photographed from public ground.