Gregory Korte

USA TODAY

WASHINGTON — A federal judge in Texas has sided with school districts opposing the Obama administration's directive on transgender bathrooms, temporarily blocking the directive just before on the first day of school in Texas Monday.

The ruling prevents the U.S. Department of Education from implementing guidance that required school districts to allow transgender students to choose which restroom and locker facilities to use.

U.S. District Judge Reed O'Connor's 38-page order said federal agencies exceeded their authority under the 1972 law banning sex discrimination in schools. The injunction applies nationwide, and follows a number of other recent court rulings against transgender students and employees.

The Texas ruling, issued late Sunday, turned on the congressional intent behind Title IX of the Education Amendments of 1972, which requires that "facilities provided for students of one sex shall be comparable to such facilities provided for students of the other sex."

"It cannot be disputed that the plain meaning of the term sex" in that law "meant the biological and anatomical differences between male and female students as determined at their birth," the judge wrote. "Without question, permitting educational institutions to provide separate housing to male and female students, and separate educational instruction concerning human sexuality, was to protect students’ personal privacy, or discussion of their personal privacy, while in the presence of members of the opposite biological sex."

Q&A: What does the Department of Education say about transgender bathrooms?

The judge also ruled that the guidance failed to follow the law requiring that it get input from the public before drafting new regulations, and suggested that the federal guidance could be implemented if the Department of Education conducts a more formal rule-making process.

And he emphasized that nothing in the law prohibits other states from requiring transgender facilities on their own. “Those states who do not want to be covered by this injunction can easily avoid doing so by state law,” he said. Other lawsuits by transgender students can also go forward, he said.

"This case presents the difficult issue of balancing the protection of students’ rights and that of personal privacy when using school bathrooms, locker rooms, showers, and other intimate facilities, while ensuring that no student is unnecessarily marginalized while attending school," wrote O'Connor, who was nominated by President George W. Bush in 2007 and sits in Fort Worth, Texas. "The sensitivity to this matter is heightened because defendants’ actions apply to the youngest child attending school and continues for every year throughout each child’s educational career."

The decision is at least the third legal setback for transgender rights in federal court this month. The U.S. Supreme Court blocked a lower court ruling requiring a Virginia school district to allow a biologically female transgender student to use the boy's restroom on Aug. 3. And last Thursday, a federal judge in Detroit upheld the firing of a transgender funeral home employee, ruling that "neither transgender status nor gender identity are protected classes" under anti-discrimination laws.

Supreme Court blocks transgender victory on bathrooms

The Texas case was brought by Texas Attorney General Ken Paxton, a Republican, who led a group of plaintiffs that included 12 other states and two school districts.

The plaintiffs argued that the Obama administration guidance came with the implicit threat that federal education funds could be withheld if school districts refused to allow transgender students to use the bathroom of their chosen gender identity. The guidance also had implications for federal student privacy laws, threatening education officials with sanctions if they fail to address students by their preferred gender pronouns.

In a statement, Paxton praised the ruling as correcting "illegal federal overreach" by the Obama administration.

"This president is attempting to rewrite the laws enacted by the elected representatives of the people, and is threating to take away federal funding from schools to force them to conform," Paxton said. "That cannot be allowed to continue, which is why we took action to protect states and school districts, who are charged under state law to establish a safe and disciplined environment conducive to student learning.”

The Texas judge’s ruling came the day before the first day of classes for most Texas public schools.

Paul Castillo, a Dallas attorney for the gay rights group Lambda Legal, called the injunction a “bump in the road” and said the case will likely proceed to the federal district court in New Orleans and the U.S. Supreme Court, where it ultimately be resolved.

“Transgender students are already at high risk of harassment and being targeted for discrimination,” he said. “This decision is certainly indicative of the harm to transgender students who are simply seeking to be treated equally in all aspects of their education.”

U.S. Justice Department spokeswoman Dena Iverson said the Obama administration was disappointed in the decision and that "we are reviewing our options.”

Contributing: Rick Jervis in Austin, Texas and Christopher Collins of the (Wichita Falls, Texas) Times Record News.