Updated

Sen. John McCain on Wednesday accused Democrats of trying to undermine U.S. military successes while advocating policies that will help Al Qaeda thrive in Iraq.

Seeking to improve his standing in the 2008 race for the White House while also reigniting Americans' resolve for war, McCain argued Democratic leaders have embarked on a course that will not only hinder U.S. surge strategy but damage efforts by Iraqis to achieve a stable government.

"I watched with regret as the House of Representatives voted to deny our troops the support necessary to carry out their new mission. Democratic leaders smiled and cheered as the last votes were counted. What were they celebrating? Defeat? Surrender? In Iraq, only our enemies were cheering. A defeat for the United States is a cause for mourning not celebrating," McCain said in a speech at Virginia Military Institute in Lexington, Va.

"Democrats argue we should redirect American resources to the 'real' War on Terror, of which Iraq is just a sideshow. But whether or not Al Qaeda terrorists were a present danger in Iraq before the war, there is no disputing they are there now, and their leaders recognize Iraq as the main battleground in the War on Terror," he said.

McCain, R-Ariz., also criticized Democrats for first confirming Gen. David Petraeus, the new head of the Multinational Force in Iraq, and then setting deadlines for troop withdrawals as part of the emergency war spending measure President Bush has requested.

"In Washington, where political calculation seems to trump all other considerations, Democrats in Congress and their leading candidates for president — heedless of the terrible consequences of our failure — unanimously confirmed our new commander and then insisted he be prevented taking the action he believes necessary to safeguard our country's interests. ... In Washington, cynicism appears to be the quality most prized by those who accept defeat but not the responsibility for its consequences," he said.

McCain's speech is part of a campaign to bolster the former Vietnam POW's credentials on Iraq policy while acknowledging problems there. A series of public events, including Wednesday's address, follows a stumble last week during a trip to Iraq, where comments he made about improving safety there were pilloried for being overly optimistic and rosy.

In his remarks, McCain singled out one Democratic presidential candidate, Sen. Barack Obama. McCain said when Bush vetoes the deadline for troop withdrawals, as he is expected to do, Democrats should take the Illinois Democrat's advice "and immediately pass a new bill to provide support to our troops in Iraq ... without substituting their partisan interests for those of our troops and our country."

In response, Obama issued a statement calling for an end to the war and jabbing McCain about his heavily-secured walk through a Baghdad market.

"Progress in Iraq cannot be measured by the same ideological fantasies that got us into this war," Obama said, again calling for a phased withdrawal to begin May 1, 2007, and be complete by March 31, 2008.

"A security detail of 100 soldiers, three Blackhawk helicopters, and two Apache gunships to walk through a market in the middle of Baghdad is simply not credible or reflective of the facts on the ground," Obama said. "The truth is, the Iraqis have made little progress toward the political solution between Shiia and Sunni which is the last, best hope to end this war. I believe that letting the Iraqi government know America will not be there forever is the best way to pressure the warring factions toward this political settlement."

In the speech, McCain sought to show his views on Iraq were based in reality as well as demonstrate his displeasure with the way his views have been portrayed by others.

"I just returned from my fifth visit to Iraq. Unlike the veterans here today, I risked nothing more threatening — nothing more threatening — than a hostile press corps," McCain said. "We still face many difficult challenges in Iraq. That is undeniable. But we have also made in recent weeks measurable progress in establishing security."

McCain said it is impossible to sugar-coat the situation, but the additional military presence he has advocated — and that Bush called for despite heavy criticism from the Democrat-led Congress — can work and must be given a chance.

"Every day we read about or watch on television the latest car-bombing, IED explosion or sniper attack. But something else is happening, too. There are the first glimmers of progress. ... While these glimmers are no guarantee of success , and though they come early in the implementation of the new strategy, I believe they are cause for very cautious optimism," McCain said.

"To deny the difficulties and uncertainties ahead is an egregious disservice to the public," McCain said. "But as General Petraeus implements his plan to correct the flawed strategy we followed in the past and attempts to spare the United States and the world the catastrophe of an American defeat, it is an equal disservice to dismiss early signs of progress."

McCain called on Democrats to support the effort now that previous failures have been addressed. He acknowledged that the Petraeus plan may not work, but initial efforts appear hopeful and no better solution has been offered.

"Democrats who voted to authorize this war, and criticized the failed strategy that has led us to this perilous moment, have the same responsibility I do, to offer support when that failure is recognized and the right strategy is proposed and the right commanders take the field to implement it or, at the least, to offer an alternative strategy that has some relationship to reality," he said.

McCain also said he is willing to support Petraeus at his own political peril.

"Will this nation's elected leaders make the politically hard, but strategically vital decision to give Gen. Petraeus our full support and do what is necessary to succeed in Iraq? Or will we decide to take advantage of the public's frustration, accept defeat, and hope that whatever the cost to our security, the politics of defeat will work out better for us than our opponents?

"For my part, I would rather lose a campaign than a war," he said.

McCain also sought to put a moral perspective on the fight by comparing a future Iraq to a situation worse than Rwanda in the early 1990s.

"I suspect many in this audience, and most members of Congress, look at America's failure to act to prevent genocide in Rwanda with shame. I know I do. But I fear the potential for genocide and ethnic cleansing in Iraq is even worse. ... Unless we fight to prevent it, our withdrawal will be coupled with a genocide in which we are complicit."

The speech was to be the first of three policy addresses by the Arizona senator as he seeks to gain ground lost to his chief GOP rivals, former New York Mayor Rudy Giuliani and former Massachusetts Gov. Mitt Romney. On Tuesday, Romney reinforced his support for Bush's strategy in Iraq in a speech at the George Bush Presidential Library Center in College Station, Texas.

Most Americans have turned against the conflict that has claimed more than 3,200 U.S. lives, according to the latest Associated Press-Ipsos poll. It showed that a majority of those surveyed say the United States made a mistake going to war in Iraq, and half called it a hopeless cause.

However, the poll said that support for the war remains strong among Republicans. Roughly three in four say the United States made the right decision in going to war and nearly the same numbers say the war is a worthy cause — something that could benefit McCain in next year's primary elections.