A high school teacher in North Texas is off the job accused of sending inappropriate text messages to a student.

But the teacher is pushing back claiming he's being let go because he's gay.

Dr. Josh Hamilton lives his life like an open book.

The 32-year-old says he's struggled with PTSD, depression and recently came out as gay.

But he says that pales in comparison to what he's going through with work.

"This has been the worst experience of my life," Hamilton said tearfully.

Hamilton teaches professional communications and college readiness at Grapevine High School. He also coaches a competitive speech team which won state and national championships last year.

Trying to repeat this year, he says last month he needed his team to focus on practice instead of personal issues.

"I was like heck, you guys watched me struggle for years through my own mental health battles, because that what it was, and come out on the other side of that has a happy functioning gay man," he recalled.

The day after coming out to his students he says he was placed on administrative leave.

He handed over his phone to administrators.

"Because I have nothing to hide," he said.

At a meeting this week, Grapevine-Colleyville ISD board members voted unanimously to move forward with firing Hamilton for violating the district's texting policy.

"Dr. Hamilton violated the standards by developing inappropriate relationships with students, providing inappropriate information to the students concerning his personal life, through text messages, treating students as family members or close friends and providing inappropriate personal information to the students," said a district human resource employee at the meeting.

Hamilton admits he's texted a student who's babysat his son in the past but insists the messages have never been inappropriate.

He believes parents caught wind of what he said and complained.

Now, he's fighting to clear his name, and get his job back.

"Sitting in the board room and hearing her use the word inappropriate, inappropriate, inappropriate painted me to the public as a child predator," Hamilton said.

The school district denies Hamilton was fired because he's gay, saying in a statement:

"Mr. Hamilton has been proposed for termination for good cause due to violations of the District's electronic communications policy, violations of student privacy, failure to follow written directives, and violations of the Texas Educator's Code of Ethics. In GCISD, we hold all employees to high standards for their interactions with our most important people, our students. His conduct is not acceptable for an educator in GCISD."

Hamilton says he plans to appeal.