PHILADELPHIA (Reuters) - Democrats Hillary Clinton and Barack Obama assailed potential White House opponent John McCain on the economy on Tuesday, accusing the Republican of favoring the wealthy and turning his back on struggling workers and middle-class families.

The Democratic presidential contenders, campaigning in Pennsylvania ahead of their April 22 showdown, took a break from attacking each other to portray the Arizona senator as uncertain and untested on economic issues.

In separate appearances but similar language, they said McCain would take his economic cues from President George W. Bush and Vice President Dick Cheney.

“John McCain admits he doesn’t understand the economy -- and unfortunately he’s proving it in this campaign,” Clinton told the Pennsylvania AFL-CIO union group.

“After seven disastrous years of George Bush and Dick Cheney, the stakes in this election couldn’t be higher and the need to change course couldn’t be more urgent. But John McCain is only offering more of the same,” the New York senator said.

Obama, an Illinois senator, said all McCain offers “is four more years of the same George W. Bush policies that have gotten us into this pickle.”

He noted McCain’s support for extending Bush’s tax cuts, which Obama said would help the wealthy, and his support for trade agreements that Obama said do not protect U.S. workers.

“His response to the housing crisis amounts to little more than standing on the sidelines and watching millions of Americans lose their homes,” Obama said in Wilkes-Barre.

The winner of the Democratic nominating battle between Clinton and Obama will face McCain in November’s election, and in recent days both candidates have toned down their attacks on each other to focus more directly on McCain.

They have criticized the former Navy fighter pilot and prisoner of war in Vietnam for saying he does not know as much about the economy as he does about national security and military issues.

McCain, on a week-long tour highlighting his military service and life story, visited his former high school outside Washington, D.C., on Tuesday.

He said he will soon offer a plan with specifics to help homeowners who are having trouble paying their mortgages because of adjustable-rate loans.

‘CHANGE THE FOCUS’

Slideshow ( 4 images )

“Senator Clinton’s attacks on John McCain are a desperate attempt to change the focus away from the divisive battle within the Democratic Party,” said Republican National Committee spokesman Alex Conant, who challenged her to explain how she will pay for her new spending proposals.

Clinton proposed a plan on Tuesday to create 3 million jobs through increased investments over 10 years in the U.S. infrastructure, and proposed a $10 billion emergency fund for critical repairs to bridges and highways.

“People ask me, “What are the issues in this campaign? I say, ‘jobs, jobs jobs and jobs,’” Clinton said at a rally in Wilkes-Barre.

Slideshow ( 4 images )

Clinton and Obama were in Pennsylvania on Tuesday ahead of the next contest when 158 pledged delegates will be at stake.

Some Democrats are concerned the prolonged campaign will hurt the eventual winner in the match-up with McCain. But Clinton, who trails Obama in pledged delegates won in state-by-state contests, has rejected calls to step aside.

Neither candidate is likely to have the 2,024 delegates needed to win the nomination after the contests end in early June, leaving the decision up to nearly 800 superdelegates -- elected officials and party insiders who are free to back any candidate.

U.S. House of Representatives Speaker Nancy Pelosi said the campaign should continue through the end of voting, and repeated her view that superdelegates should not be perceived to overturn the will of the voters.

“I think the election has to run its course,” Pelosi said on ABC’s “Good Morning America.”

“I do think that it is important for us to get behind one candidate a long time before we go to the Democratic National Convention if we hope to win in November,” she said.

Obama also played down worries the long campaign would hurt the eventual Democratic nominee.

“I think this contest has been good for the Democratic Party. We’ve brought in all kinds of new people into the process. And I think that bodes well for November,” he said on NBC’s “Today” show.

(Additional reporting by David Morgan, Caren Bohan and Steve Holland, writing by John Whitesides; editing by Vicki Allen)