Rules for dating a law student
(b) An offense under this section is a felony of the second degree. But he was sacked from his position and will (IMHO rightly) be never allowed to teach in Queensland again. He won't teach again, and I would guess from what I have read that he will be convicted: not just of profession misconduct, but or criminal activity, and serve time.
(c) If conduct constituting an offense under this section also constitutes an offense under another section of this code, the actor may be prosecuted under either section or both sections. The case in NZ has boiled down to a conflict over whose version of events to believe. So, to summarise, it does vary from jurisdiction to jurisdiction, but professional standards for teachers are commonly set at a higher level; which means that a teacher is in trouble long before any laws are broken. Illinois." However, the rest of your question appeared to be more general.
..wait, this is America, land of the sodomy is illegal in several states.
For example can a high school teacher in Illinois date and have sex with a 17 year old girl in his class?
This is assuming both teacher and student are otherwise adults and able to make their own decisions.
People below the age of consent are by definition not able to meet adults as legal equals (though of course this varies all over the map according to jurisdiction).
I doubt a teacher-student relationship per se is against the law. Yes, I wasn't specific enough but the OP didn't specify either country or state so I was trying to answer more generally. Especially since just in the last couple of days there have been very public court cases on the matter in Australia and New Zealand -- the two countries where I have taught.
It's definitely against school policy though, and will get the teacher fired. (Two cases in Queensland, one in my home town broke today.