There was a sense, just a few years ago, that Seth Williams was a man to watch in Philadelphia politics.

Turns out the feds were watching him, too.

Williams pushed a strong personal and political narrative — adopted by loving parents who raised him to work hard, class president at Pennsylvania State University, service in the Army National Guard and as a rising city prosecutor.

He finally captured the post of district attorney in 2009 after losing a challenge to his former mentor, Lynne M. Abraham, in 2005.

"He could have been a talented guy," said U.S. Rep. Robert Brady, chairman of Philadelphia's Democratic City Committee. "Everyone knows he had ambition. He wanted to be mayor. He was a rising star at one time. Look at him now."

Williams on Thursday pleaded guilty to a count of bribery. His plea agreement allows the judge to consider the 28 other counts he had been charged with when he is sentenced Oct. 24. That includes allegations that Williams took bribes from two businessmen and stole money meant for the care of his elderly mother.

"I'm pretty shocked out of my socks," Abraham said of the plea agreement. "I mean, the chief law enforcement officer of the city of Philadelphia convicting himself out of his own mouth of all these things is pretty depressing."

Williams, a Democrat, also resigned six months before the end of his second term.

Samuel Stretton represented Williams in 2016 when he amended five years of statements of financial interest to disclose $164,000 in previously unreported gifts.

Stretton, who said he spoke to Williams at 11 p.m. Wednesday, said he was "stunned" to hear about his guilty plea.

And he expressed concern because Williams was immediately taken into custody and will be held in federal detention until his sentencing.

"I'm shocked that they didn't work out a deal to keep him out on the street," Stretton said. "That puts Seth Williams in a very dangerous situation. I'm a little taken back by that. He could have stayed out until his sentencing."

Kathleen Martin, who was chief of staff for Williams until he made her interim district attorney in March by agreeing to a temporary suspension of his law license, deflected a question Thursday about how she felt about his fall. Martin said her feelings didn't matter.

"I think that he made a lot of progressive changes that did a lot of good," Martin added.

Beth Grossman, the Republican nominee for district attorney in the Nov. 7 general election, agreed that Williams brought reform to the office.

"Nobody is above the law," Grossman said. "I think what it says is, the office needs now more than anything someone who brings integrity and a high sense of ethics to help rebuilding morale and a sense of trust."

Mayor Kenney and Gov. Wolf had called on Williams to resign after he was indicted in March. Williams refused and continued to draw a paycheck for his $175,572 annual salary.

Kenney, in a statement released by a spokeswoman, said he was glad Williams had resigned.

"I wish he'd done it much, much sooner, but I'm glad for the employees of the DA's Office and for the people of Philadelphia that it's over," Kenney said. "Now we can finally move on to a new chapter."

Wolf, through a spokesman, called the resignation "in the best interest of the dedicated public servants in the District Attorney's Office and for the people of Philadelphia."

Williams could have kept collecting his salary until sentencing if he didn't resign. He told a judge Thursday he had $200 or less in the bank.

Stretton said the temporary suspension of Williams' law license will likely become a disbarment. The state Supreme Court, which rules on the discipline of lawyers, has previously permanently banned people from practicing law after a bribery conviction.

"I worry about what he's going to do for a career after his sentence is over," Stretton said.

Read a recap of Philadelphia District Attorney Seth Williams' trial with our day-by-day updates and learn more with our explainer on everything you need to know about the case.