(Reuters) - Larry Langford, the charismatic former mayor of Birmingham, Alabama, who climbed out of hardscrabble poverty to the city’s highest office only to spend most of his last years in prison, died Tuesday, the city announced.

All flags in the city were lowered to half-staff under current Mayor Randall Woodfin’s request to honor Langford, 72, whom he called a visionary.

The former mayor died in a Birmingham hospital surrounded by family and friends after failing health, the Birmingham News reported.

Langford was released from federal prison a few weeks ago after a federal judge reduced his 15-year prison sentence so he could seek medical attention, the newspaper reported.

Langford was convicted in 2009 on 60 criminal charges ranging from bribery, mail and wire fraud to criminal conspiracy after a corruption probe at the heart of a multibillion-dollar sewer debt, which forced the city to the brink of bankruptcy.

Langford, a Democrat, was the head of the city commission when the much of the debt was accumulated. He became mayor in 2007 and only served 2 years before his conviction in federal court.

He was accused of receiving more than a quarter-million-dollars worth of cash, jewelry, clothes and other gifts in a kick-back scheme for city business between 2002 and 2007.

Local media described Langford as a man full of contradictions.

He swore like a sailor but was devoutly religious, attended Mass regularly and taught Sunday school classes, the Birmingham paper reported.

He grew up in a housing project and at one point said he thought as a youth he was headed to either jail or an early grave.

As an elected official in both city and county offices, he was a driving force behind building schools and putting laptops in the hands of needy students, media reported.

When he was convicted, he told Reuters: “We all have trials and this too shall pass.”

But it turned out he would spend most of his last years in a jail cell.

Nonetheless he remained popular in the state’s largest city.

Mayor Woodfin made no mention of Langford’s fall from grace.

“Langford had an unmatched love for his community - a love he expressed through his boldness and creativity,” he said in a statement.

“Above all else, Mayor Langford loved this city.”