No homeowner wants to fall behind on his mortgage payments, but if it's going to happen, Philadelphia just might be the best place to manage to keep a roof over your head.

A new study has found that the city's widely cited foreclosure-diversion program, which is run by Common Pleas Court, has had remarkable success in helping homeowners facing foreclosure avoid having their homes taken.

Since it began in 2008, court-ordered negotiations between lenders and homeowners participating in the program have enabled nearly twice as many owners to work out repayment agreements.

Also significant, according to the study done by Ira Goldstein at the Reinvestment Fund, was the fact that low-income and minority homeowners have been just as successful as wealthier owners in reaching deals with lenders.

The program was started as a pilot by Judge Anita Rizzo. Had it relied on a gimmick like a moratorium on foreclosures, it would have helped few owners in the long run. The process of holding face-to-face talks, with financial counselors assisting qualified homeowners, has also provided a greater assurance of fairness.

It is clear from the study, funded by the William Penn Foundation and the Open Society Institute, that the city courts should continue this valuable program. Given its proven success, the foreclosure-diversion effort should contribute to a positive business climate for lenders, homeowners, and would-be sellers alike.