Less than two weeks after Temple University began in-person classes with cautious optimism, the school reversed course Thursday and moved almost all instruction online for the rest of the semester amid a coronavirus outbreak.

It’s becoming a pattern at some large universities around the country, which are recording hundreds, in some cases more than 1,000, virus cases after bringing students back for classes.

Temple University psychology professor Laurence Steinberg was not surprised. He had warned in a June New York Times opinion piece that reopening plans counting on students to wear masks and socially distance bordered on “delusional.”

“I gave the experiment a few weeks,” he said Thursday. “Looks like at bigger schools it’s not even that long before it’s clear the plan isn’t working.”

Pennsylvania State University, Villanova University, and St. Joseph’s University are among schools operating with some in-person instruction and many students back on campus. Others have retreated. Bloomsburg University, with 216 cases, moved instruction online last week, and Columbia County, home to Bloomsburg, has the state’s highest daily case count per 100,000 residents.. Lock Haven University, which also saw a spike, paused in-person instruction until later this month.

Temple’s decision follows weeks of lobbying by faculty union and student leaders to move instruction online. Case counts have been climbing since classes started Aug. 24, when there were 10 cases. By Wednesday, there were 237 active cases. Of them, 60 were recorded by the Philadelphia Department of Public Health on Monday out of nearly 400 tests given — a 15% positivity rate the department has called an outbreak.

“We have concluded that the data indicate it is time to pivot to primarily online education, as we said we would be prepared to do,” president Richard M. Englert and provost JoAnne A. Epps announced to the campus Thursday.

Only about 5% of classes, those deemed essential for in-person teaching, will remain face-to-face.

While Temple’s faculty union applauded the decision, its president questioned which classes the school intends to keep in-person.

“The union needs to know right now, who among our members … are being required to continue doing their duties on campus in the midst of a pandemic,” said Steve Newman. “We need to know that and we need to have some way of contesting that.”

About 3,200 students live on the North Philadelphia campus. To thin that number, Temple offered a full housing and meal refund to those who leave university housing by Sept. 13. It’s unclear how many will.

“I would imagine most parents would want their students to come home,” said Quinn Litsinger, president of the Temple Student Government Association.

But he’s doubtful the thousands of students who live off campus and pay rent — including himself — will leave. And that’s where most confirmed infections have occurred, often in small social gatherings. Fewer than a dozen cases came from students in university housing, Temple spokesperson Ray Betzner had said.

“Anything we can do to thin out the number of people on campus is helpful to us from a disease perspective,” said James Garrow, a city health department spokesperson.

Public Health Commissioner Thomas Farley and Mayor Jim Kenney said Temple did everything it could to limit the spread of the virus while also offering in-person learning, and was successful in doing so in settings it could control, such as classrooms and dorms. But the school was unsuccessful in encouraging students to practice adequate safety measures off campus, they said.

Reaction to Temple’s decision was brisk, and some of it scathing.

“Thank you so much for pretending that this wasn’t going to be the result all along,” a parent tweeted. “Besides having paid full tuition, my son is now locked into an off campus leased apartment. I’ve never been more disgusted.”

Sara Goldrick-Rab, a Temple professor whose work has focused on homeless and hungry college students, largely blamed the state for failing to properly fund higher education and the federal government for failing to stop the pandemic or deliver the money needed to support students.

“Given those constraints, Temple tried to avoid a financial disaster by offering classes so students would return — and housing because thanks to state defunding we must make money from food and housing to make the budget work,” she said.

Terry W. Hartle, senior vice president at the Washington-based American Council on Education, also blamed lack of national leadership and clear standards on testing and contact tracing. Schools heard overwhelmingly from students that they wanted an in-person experience, he said.

“Temple has handled it about as well as they could have done,” he said.

But some have been critical of the school’s plan and its potential danger to the surrounding North Philadelphia community.

One professor said the university never informed them that a student who had been in their class had tested positive and was in isolation; the student herself told the professor.

.

“That lack of communication and lack of protocol made it clear that Temple’s plan was not going to protect the community,” said the professor, who asked not to be identified for fear of backlash from Temple.

Betzner responded that such notifications aren’t required when a class follows Centers for Disease Control and Prevention guidelines over proper social distancing and mask-wearing — and someone still tests positive.

Newman, of the faculty union, said he hopes Temple will learn from the experience. “The spring,” he said, “is likely to face us with many of the same challenges.”

What’s unclear is when classes will resume at schools forced to halt in-school instruction. It’s also uncertain whether colleges still teaching students in classrooms will continue.

One such school, Villanova, where the case count stands at 42, isn’t planning a change.

“We understand that this is a fluid situation and change can happen rapidly,” spokesperson Jonathan Gust said. “Villanova continues to have ample facilities for quarantine and isolation available, as needed.”

Staff writers Tom Avril, Frank Kummer, and Sean Collins Walsh contributed to this article.