In the midst of his career-threatening sex scandal, a deeply worried David Letterman has turned for advice to old, trusted friend Regis Philbin.

It was Regis who advised Dave to make his startling public confession, The ENQUIRER has learned.

The 78-year-old daytime talk legend also came up with more surprising advice for his 62-year-old pal: Expand your family!

"Obviously, you and Regina want to have more kids," Regis, a father of four, told Dave, according to a source. "Now would be a good time to be working on that."

Letterman married his longtime girlfriend Regina Lasko last March. They already have a 6-year-old son, but Dave quipped to his buddy he’d "sleep on it," according to an insider.

Last week, The ENQUIRER disclosed that Letterman has been rocked by reports of a purported sex tape showing him with a female staff member. A studio surveillance camera reportedly caught Letterman and a much-younger female co-worker in a compromising position, say sources.  We also disclosed charges that Dave’s illicit romance with his 34-year-old personal assistant Stephanie Birkitt continued after he married Regina.

The secret affair exploded when Stephanie’s jealous ex-lover Robert "Joe" Halderman allegedly tried to blackmail Letterman for $2 million, and Dave went public with the extortion attempt.

"Regis is more than just a friend to Dave," said the insider. "He’s the one guy he really trusts for his wisdom and experience.  "When Dave was having his heart bypass surgery, Regis was the first one he called – he even used Regis’ heart surgeon."

So when the sex scandal was about to explode, Letterman turned to his longtime pal..

"Regis thought another child for Dave would give people something else to focus on rather than just the scandal," explained the insider.

"But nothing will happen unless Regina is onboard – and right now she’s barely even talking to Dave."