The teacher insisted she was simply following a format that had worked in her classroom for a quarter of a century: Encourage her students to write, then work to refine it.

The school board disagreed, saying English teacher Cissy Lacks did too little refining when she allowed her 11th-graders to act in skits loaded with raw street language.Lacks sued to get her job back and won, but a three-judge panel of the 8th U.S. Circuit Court of Appeals overturned that verdict Monday. The judges said the suburban St. Louis school district had the right to fire Lacks for violating its policy banning profanity.

"Isolated instances of profanity had been overlooked or tolerated in the past, but what went on in Lacks' classroom went far beyond the reading aloud of a novel containing the occasional `damn,' " Chief Judge Richard S. Arnold wrote.

Lacks, a 25-year teaching veteran, was fired from her job at Berkeley High School in 1995 after asking an 11th-grade English class to divide into groups and write short plays.

Those plays were then performed for other students in the class and videotaped. The 40-minute videotape contained more than 150 vulgar words, court records showed.

A student complained to administrators, who dismissed Lacks for failing to enforce Ferguson-Florissant School District's discipline code, which prohibits profanity.

Lacks said her teaching methods were designed to allow students to be creative. "Why do you do something to a teacher who is making it work?" she asked. "I was doing my best in an honorable way."

In 1996, jurors awarded Lacks $750,000 after finding that the district violated her First Amendment right to free speech. The panel also said that Lacks, who is white, had been racially discriminated against by black school officials.

The appeals court's reversal on Monday stunned the former English and journalism teacher.

"It was devastating. It was frightening," she said. "Everything I thought I was doing right has now been dismissed." Lacks did not know whether she would appeal.